# Cloudflare consultant: Workers, cron triggers and R2 storage that do the heavy lifting.

> SBD uses Cloudflare Workers and R2 to take heavy or high-volume processing out of no-code tools and store documents cheaply, for teams of 1 to 1,000 people, in a Cloudflare account in your name. Workflow automation builds start at $1,000, with the fixed price set after a $500 Automation Audit that is credited to the build.

- Canonical: https://smallbaydigital.com/integrations/tools/cloudflare/
- Publisher: SmallBay Digital

## What a Cloudflare developer from SBD builds

We mostly use Cloudflare as a workhorse behind other tools. A Worker takes a job that would cost many operations or tasks in Make or Zapier, such as generating a report, reshaping a large payload or calling several APIs in sequence, and does it in one request. R2 holds documents and files with signed links, so a database row stores a key rather than the file itself.

Four published SBD projects use Cloudflare. In a [multi-user production dashboard](https://smallbaydigital.com/case-studies/manufacturer-dashboard/), report generation runs on Cloudflare Workers with direct printing through PrintNode. In an [automated cashback and loyalty system](https://smallbaydigital.com/case-studies/customer-loyalty-system/), Make works with Cloudflare Workers and the Razorpay X payout APIs. For a [photo studio](https://smallbaydigital.com/case-studies/photo-studio-project-management/), heavier processing moved to Apps Script and Workers to keep automation costs down. And in a [loan broker CRM](https://smallbaydigital.com/portfolio/loan-broker-crm/), KYC and loan documents are stored in R2 and uploaded through signed links.

## When Cloudflare Workers are the right choice, and when they are not

Workers suit short, stateless jobs that are triggered by an HTTP request or a schedule: webhook receivers, payload transformations, report generation, light APIs and fan-out calls to other services. On the Paid plan Cloudflare does not charge for duration, only for requests and CPU time, so a Worker that spends most of its time waiting for a slow third-party API costs very little. R2 suits documents, exports and media that are downloaded often, because it charges no egress fee.

We will use something else when:

- The job needs a full Node.js environment, large native libraries or more than 128 MB of memory; a Vercel function or a small server is easier.
- The team needs to change the logic often without a developer; a Make or n8n scenario they can read is worth the extra operations.
- The data has to live in a relational database with row-level permissions; Supabase or Postgres does that, with Workers in front if needed.
- Volume is tiny; the Free plan may be enough, or the work belongs inside an existing tool.

## Workers and R2 pricing, and the limits that shape a design

From Cloudflare's developer documentation in October 2026:

- **Workers Free:** 100,000 requests a day; 10 milliseconds of CPU per invocation; 50 subrequests per invocation; 5 cron triggers per account.
- **Workers Paid:** from $5 a month per account, including 10 million requests and 30 million CPU milliseconds a month, then $0.30 per extra million requests and $0.02 per extra million CPU milliseconds; no charge for duration.
- **Paid limits:** 30 seconds of CPU per request by default, configurable up to 5 minutes; 10,000 subrequests per invocation; 128 MB memory per isolate; 64 MiB Worker size; 250 cron triggers per account.
- **Request body size:** set by the Cloudflare account plan, separate from the Workers plan: 100 MB on Free and Pro, 200 MB on Business.
- **R2 Standard storage:** $0.015 per GB-month, $4.50 per million Class A operations, $0.36 per million Class B operations, free egress; the monthly free tier covers 10 GB, 1 million Class A and 10 million Class B operations.

## Tokens, secrets and the traps we design around

Cloudflare API tokens can be scoped to specific permissions and resources, restricted by client IP and given an expiry. The secret is shown once, and new tokens carry a recognisable prefix so leak scanners can find them. We create account-owned tokens for service use, scoped to the one Worker, bucket or zone a job needs, rather than tokens tied to a person who might leave.

Three traps come up repeatedly. First, CPU time is not wall time: a Worker that parses a large spreadsheet can exceed its CPU budget even though it finishes quickly, so we stream and chunk heavy work. Second, R2 Class A operations cost twelve and a half times as much per million as Class B, so we check which class each call in a frequent sync falls into, and store file keys in the database rather than repeatedly listing the bucket. Third, a Worker should not rely on memory between requests, so anything that must survive goes to R2 or your own database.

Secrets live in Worker secrets, never in code, and every scheduled Worker logs its result somewhere a person will see a failure.

## How a Worker fits alongside Make, n8n and your apps

The most common pattern is a Worker called from an automation platform. A Make scenario or n8n workflow sends one HTTP request to the Worker with a shared secret in a header; the Worker does the heavy part, such as merging data from several APIs, building a PDF or reshaping a large file, and returns a small result. The scenario stays readable for your team, and the expensive loop that used to run as hundreds of separate operations becomes one request.

The second pattern is a scheduled Worker on a cron trigger that replaces a script on someone's laptop: a nightly report, a reconciliation, a reminder run. Each run writes a row recording when it started, what it did and whether it failed, so a missed night is visible the next morning.

The third is document handling with R2. Your app asks a Worker for a short-lived signed upload link, the browser uploads straight to the bucket, and the database stores only the object key, the uploader and the time. Files never pass through a function body, so the request size limits never come into play.

## How hiring a Cloudflare consultant from SBD works

Every engagement starts with an [Automation Audit](https://smallbaydigital.com/services/audit/) at $500, credited in full to your build. When Cloudflare is in scope it is usually because an automation platform bill has grown or a step keeps timing out; the audit measures the operations or tasks each step consumes and shows what moving it to a Worker would save. You get a ranked list of changes, each with a fixed price.

Workflow automation builds start at $1,000, internal tools at $3,000 and multi-module systems at $5,000. Work runs in two-week sprints with sixty days of hypercare, and care plans start at $50 a month. Cloudflare bills your account directly.

## What you own when the build is finished

The Cloudflare account, every Worker, bucket and token are in your name, and the source is in your Git repository with a deployment script. You receive a runbook for each Worker and cron trigger that says what it does, what it costs at current volume, how to redeploy it and who is alerted on failure.

If a Worker later needs to move, for example into a Vercel function next to the rest of an app, the code is plain JavaScript or TypeScript and moves with modest changes. Book a discovery call to talk through the job you want off your automation bill.

## At enterprise scale

Most larger organisations already have Cloudflare in front of their websites, run by a network or security team. Workers and R2 often arrive later, from application teams who want edge logic or cheap storage, which means the account, the access model and the billing are owned by someone other than the people building on it.

- **Working inside an existing account** We agree with your network or security team which account and zones we may touch, and work through scoped tokens they can see and revoke, never a global key.
- **Least-privilege tokens** Each job gets a token limited to its own Worker, bucket or zone, with IP filtering and an expiry where the job allows. Tokens are account-owned so they survive staff changes.
- **Document storage and access** We keep buckets private and serve files through short-lived signed links issued by your application, with the access rule written down and tested.
- **Cost control at volume** We model requests, CPU time and R2 operations against your real traffic before go-live, and design listings and writes so Class A operations stay low.
- **Change control** Workers deploy from your Git repository through a scripted pipeline, so every change is reviewed and can be rolled back to a known version.
- **Monitoring** Each Worker writes its outcome to a log or monitoring tool you own, and failures alert a named person rather than waiting to be noticed.

### Engagements

- **Already on Cloudflare, automation bill too high.** A Make or Zapier scenario burns thousands of operations on data reshaping. We move that step into a Worker and leave the readable parts of the scenario in place, then report the saving.
- **Already on Cloudflare, documents scattered.** Files sit in email, shared drives and app attachments. We set up R2 with signed upload and download links from your app, and a database record for every file.
- **Already on Cloudflare, Workers nobody owns.** A past contractor deployed Workers from a laptop. We bring the code into your repository, rotate tokens, document each one and set up monitoring.
- **Already on Cloudflare, need scheduled jobs.** Nightly reports and syncs run from someone's machine. We move them to cron-triggered Workers with logs and alerts, within your plan's trigger allowance.

## Related

- [Case study: production dashboard with Workers](https://smallbaydigital.com/case-studies/manufacturer-dashboard/)
- [Case study: cashback and loyalty system](https://smallbaydigital.com/case-studies/customer-loyalty-system/)
- [Cloudflare portfolio](https://smallbaydigital.com/portfolio/tools/cloudflare/)
- [Make automation](https://smallbaydigital.com/integrations/tools/make/)
- [The Zapier tax in 2026](https://smallbaydigital.com/blog/the-zapier-tax-in-2026/)
- [Integrations](https://smallbaydigital.com/services/integrations/)

## Sources

- Cloudflare: Workers pricing (Free and Paid plans, included usage, overage, duration), checked 29 October 2026 <https://developers.cloudflare.com/workers/platform/pricing/>
- Cloudflare: Workers limits (CPU, subrequests, memory, size, cron triggers, body size), checked 29 October 2026 <https://developers.cloudflare.com/workers/platform/limits/>
- Cloudflare: R2 pricing (storage, operations, egress, free tier), checked 29 October 2026 <https://developers.cloudflare.com/r2/pricing/>
- Cloudflare: Create an API token (scopes, resources, IP filtering, expiry), checked 29 October 2026 <https://developers.cloudflare.com/fundamentals/api/get-started/create-token/>
