Cloudflare Is So Much More Than "I'm Not a Robot"

Ask a room of developers what Cloudflare does and you tend to hear: "the 'I'm not a robot' checkbox, right? And a CDN or something?"
That checkbox is a tiny corner of it. You can host a frontend, run an API, query a SQL database, store files, coordinate live users, process background jobs, call AI models, receive email and publish a server from behind your home router, much of it on a free plan.
This post is organised by what you want to do. For each job you get the product, the free allowance, the catch, and code.
A note on honesty: the database, counter, WebSocket, rate limit, bot check, queue, workflow, email and cron examples were run on my machine with Wrangler's local simulator, which needs no Cloudflare account. Outputs shown are from those runs. The AI, Tunnel and Access snippets need a real account and follow the official docs. Limits were checked against those docs on 30 November 2026, and they do change.

First, how Cloudflare actually works
Cloudflare began as something you put in front of a website. Your domain's traffic goes to Cloudflare's network first, and anycast routing delivers each visitor to a nearby data center. Filtering, caching and your own code run there.

That code runs in Workers. Workers do not give each app a container or a virtual machine. They run your JavaScript, TypeScript, Python or Wasm inside V8 isolates, lightweight sandboxes that share one runtime process. Cloudflare's docs say an isolate can start around a hundred times faster than a Node process on a container or VM, which removes the cold starts of the VM model.
The Free plan limits that shape your design:
| Workers Free | Limit |
|---|---|
| Requests | 100,000 per day |
| CPU time | 10 ms per invocation |
| Memory | 128 MB |
| Subrequests | 50 per request |
| Workers per account | 100 |
10 ms of CPU is more than it sounds. Time spent waiting on a fetch, a database query or a KV read does not count. A handler that waits two seconds on a model API can still use only a few milliseconds of CPU. Parsing a huge JSON file or resizing an image in JavaScript is what will hurt.
Everything else (databases, buckets, queues, models) reaches your Worker through bindings: you declare a resource in config and it appears on env. No connection strings or API keys in your code.
1. Ship a website or a full-stack app

For new projects, Cloudflare now points you to Workers with Static Assets. Requests for static files are free and unlimited; only requests that run your code count toward the 100,000.
// wrangler.jsonc
{
"name": "my-app",
"main": "src/index.js",
"compatibility_date": "2026-09-01",
"assets": {
"directory": "./dist",
"not_found_handling": "single-page-application",
"run_worker_first": ["/api/*"]
}
}
npm run build
npx wrangler deploy
That is a React or Vue app plus its API in one deploy, with no CORS setup. The free plan allows 20,000 files per version, up to 25 MiB each.
Cloudflare Pages still works and is still a good home for existing projects: 500 builds a month, one build at a time, 100 custom domains per project and 20,000 files per site.
2. Query a real SQL database (D1)
D1 is managed SQLite. Free: 10 databases of up to 500 MB each, 5 GB in total, 5 million rows read and 100,000 rows written per day.
The word to notice is rows read. D1 meters the rows your query touches, not the rows it returns. I seeded 10,000 phone calls across 100 callers and asked for one caller's 10 latest:
const { results, meta } = await env.DB.prepare(
'SELECT id, started_at FROM calls WHERE caller = ? ORDER BY started_at DESC LIMIT 10',
).bind('caller-42').all()
return Response.json({ returned: results.length, rows_read: meta.rows_read })
{"returned":10,"rows_read":10100}
# EXPLAIN QUERY PLAN
SCAN calls
USE TEMP B-TREE FOR ORDER BY
Then one line of SQL:
CREATE INDEX idx_calls_caller_time ON calls (caller, started_at);
{"returned":10,"rows_read":10}
# EXPLAIN QUERY PLAN
SEARCH calls USING COVERING INDEX idx_calls_caller_time (caller=?)

Without the index, about 495 of these queries use up the day's allowance. Check meta.rows_read while you build, not after you hit the limit.
Already have Postgres or MySQL? Hyperdrive pools and caches connections from Workers to your existing database, with 100,000 queries a day on the Free plan.
3. Pick the right kind of state (KV vs Durable Objects)
This is the mistake that is easiest to make and hardest to notice in a demo.
Workers KV is a global key-value store for data that is read often and written rarely. Free: 100,000 reads and 1,000 writes per day, 1 GB stored. It is eventually consistent: a change can take 60 seconds or more to appear in other locations. So this counter is broken:
const n = Number((await env.KV.get('n')) ?? 0) + 1
await env.KV.put('n', String(n))
A Durable Object is a single named instance, single-threaded, with its own strongly consistent storage. Every request for the same name reaches the same object.
import { DurableObject } from 'cloudflare:workers'
export class Counter extends DurableObject {
async increment() {
const n = ((await this.ctx.storage.get('n')) ?? 0) + 1
await this.ctx.storage.put('n', n)
return n
}
}
// in the Worker
const stub = env.COUNTER.getByName('page-views')
return new Response(String(await stub.increment()))
I fired 100 requests at once at each version. All 200 requests returned success. The exact KV total changes from run to run, but it lands nowhere near 100.

On the real network KV also limits writes to the same key to one per second, so expect errors there on top of lost updates. The local simulator did not enforce that.
Use KV for feature flags, config and cached responses. Use Durable Objects for counters, inventory, bookings, locks and anything where two requests must not disagree. On the Free plan you get SQLite-backed objects with 100,000 requests per day and 5 GB of storage.
Live chat and multiplayer
Because one object owns one name, it is a natural chat room, game lobby or shared document. It can hold the WebSockets itself:
export class Room extends DurableObject {
async fetch() {
const [client, server] = Object.values(new WebSocketPair())
this.ctx.acceptWebSocket(server) // allows hibernation while idle
return new Response(null, { status: 101, webSocket: client })
}
webSocketMessage(sender, message) {
for (const socket of this.ctx.getWebSockets()) {
if (socket !== sender) socket.send(message)
}
}
}
I connected A and B to lobby and C to another room, then sent a message from A. B received hi from A; C received nothing. Duration charges do not accrue while an object hibernates.
4. Store files without egress fees (R2)
R2 is S3-compatible object storage. Free each month: 10 GB stored, 1 million Class A operations (writes, lists) and 10 million Class B operations (reads). Data transfer out to the internet is free.
await env.BUCKET.put('uploads/photo.jpg', request.body)
const object = await env.BUCKET.get('uploads/photo.jpg')
if (!object) return new Response('Not found', { status: 404 })
return new Response(object.body, { headers: { etag: object.httpEtag } })
Two catches. You have to add an R2 subscription through a checkout flow before using it, and usage above the free tier is billed. And "free egress" is not "free reads": Cloudflare's own pricing example of 10 million reads a day comes to $104.40 a month in operations. Cache popular files.
For responsive images, Cloudflare Images can resize and reformat pictures stored in R2 or elsewhere, with 5,000 unique transformations a month on the free plan.
5. Do slow work in the background (Queues, Workflows, Cron)
Nobody should watch a spinner while you call a model or generate a report. Accept the upload, queue a job, answer immediately.

// producer
await env.BUCKET.put(key, request.body)
await env.JOBS.send({ key })
return Response.json({ queued: key }, { status: 202 })
// consumer
async queue(batch, env) {
for (const msg of batch.messages) {
await env.PIPELINE.create({ params: msg.body })
msg.ack()
}
}
A Workflow splits the job into steps that are saved and retried independently:
export class Pipeline extends WorkflowEntrypoint {
async run(event, step) {
const text = await step.do('load transcript', async () => {
const obj = await this.env.BUCKET.get(event.payload.key)
return obj.text()
})
const words = await step.do(
'summarise',
{ retries: { limit: 3, delay: '1 second', backoff: 'exponential' } },
async (ctx) => {
console.log(`summarise: attempt ${ctx.attempt}`)
// stand-in for a flaky model API: fail twice, then succeed
if (ctx.attempt < 3) throw new Error('upstream 503')
return text.trim().split(/\s+/).length
},
)
await step.do('save result', async () => {
await this.env.DB.prepare('INSERT INTO results (file, words) VALUES (?, ?)')
.bind(event.payload.key, words)
.run()
})
}
}
The log from the run:
queue: received 1 message(s)
summarise: attempt 1
✘ [ERROR] Uncaught Error: upstream 503 Error
summarise: attempt 2
✘ [ERROR] Uncaught Error: upstream 503 Error
summarise: attempt 3
The free math: Queues gives 10,000 operations a day, and delivering a small message usually takes three (write, read, delete), so about 3,300 messages. Messages are kept for 24 hours. Workflows gives 3,000 steps a day, not counting retries, so about 1,000 runs of this three-step pipeline.
For scheduled work, Cron Triggers (5 per account on Free) call a scheduled handler. Times are in UTC, so midnight in India is 30 18 * * *:
async scheduled(controller, env) {
await env.DB.prepare('DELETE FROM calls WHERE started_at < ?').bind(cutoff).run()
}
6. Build AI features
Workers AI runs open models for text, embeddings, speech and images through a binding. Vectorize stores embeddings. AI Gateway adds analytics, caching and rate limiting to model calls, and those core features are free.

npx wrangler vectorize create docs --dimensions=1024 --metric=cosine
// needs a Cloudflare account: AI and Vectorize bindings
const embedded = await env.AI.run('@cf/baai/bge-m3', { text: [question] })
const { matches } = await env.VECTORS.query(embedded.data[0], {
topK: 5,
returnMetadata: 'all',
})
const context = matches.map((m) => m.metadata.text).join('\n---\n')
const answer = await env.AI.run(
'@cf/meta/llama-3.1-8b-instruct-fp8-fast',
{
messages: [
{ role: 'system', content: `Answer only from this context:\n${context}` },
{ role: 'user', content: question },
],
},
{ gateway: { id: 'default' } },
)
Workers AI is free for 10,000 Neurons a day (Neurons are Cloudflare's unit of GPU work). How far that goes depends heavily on the model:

Vectorize's free allowance is counted in dimensions: 5 million stored and 30 million queried per month. A 4,000-chunk index of 1,024-dimension vectors stores 4.1 million. Because queried dimensions are calculated as (stored vectors + queries) × dimensions, that leaves room for roughly 25,000 queries a month.
If you would rather not wire the pipeline yourself, AI Search manages indexing and retrieval for you, with 1,000 semantic queries a month included.
Voice and video
For real-time apps, Cloudflare Realtime offers an SFU for routing media and a TURN relay for clients behind strict networks. The two share a 1,000 GB free tier, and the STUN service is free and unlimited. If you build voice agents, that is worth knowing before you pay for a relay.
7. Stop bots and abuse
Turnstile: the checkbox, done properly
In April 2022 Cloudflare wrote that it had cut the number of CAPTCHAs it served by 91% and was working to remove them. Turnstile brings that approach to any site, whether or not it uses Cloudflare's CDN. It runs small non-interactive checks in the browser instead of asking people to pick out traffic lights, and has been generally available and free since September 2023.

<script src="https://challenges.cloudflare.com/turnstile/v0/api.js" async defer></script>
<div class="cf-turnstile" data-sitekey="YOUR_SITEKEY"></div>
The widget alone protects nothing. You must verify the token on your server:
const res = await fetch('https://challenges.cloudflare.com/turnstile/v0/siteverify', {
method: 'POST',
headers: { 'content-type': 'application/json' },
body: JSON.stringify({ secret: env.TURNSTILE_SECRET, response: token }),
})
const outcome = await res.json()
if (!outcome.success) return Response.json({ error: 'verification failed' }, { status: 403 })
Tokens expire after 5 minutes and are meant for a single use. The free plan includes unlimited challenges and verifications, 20 widgets and 10 hostnames per widget.
Rate limiting inside your code
The edge can only guess who your users are. Your code knows. The rate limiting binding lets you limit by user ID, API key or route:
"ratelimits": [
{ "name": "LIMITER", "namespace_id": "1001", "simple": { "limit": 5, "period": 10 } }
]
const { success } = await env.LIMITER.limit({ key: userId })
if (!success) return new Response('slow down', { status: 429 })
Eight quick requests from one user, locally:
200 200 200 200 200 429 429 429
In production the counts are approximate and kept per Cloudflare location, so use it to stop abuse, not to bill customers.
What your domain gets for free
Put a domain on the free plan and you also get unmetered DDoS protection, the Free Managed Ruleset in the WAF, 5 custom firewall rules and 1 rate limiting rule.
8. Share a local server, safely (Tunnel and Access)
Cloudflare Tunnel runs a small program, cloudflared, on your machine. It makes an outbound connection to Cloudflare, so you open no inbound ports and need no public IP.

For a quick demo you do not even need an account:
cloudflared tunnel --url http://localhost:3000
# only let named people in: visitors get a one-time PIN by email
cloudflared tunnel --url http://localhost:3000 --allowed-mail you@example.com
Quick Tunnels are for testing: they allow 200 requests in flight and do not support Server-Sent Events. For anything lasting, create a named tunnel on your own domain.
Cloudflare Access, part of Zero Trust (free for up to 50 users), puts a login page in front of an admin panel or internal dashboard without you writing any auth. Do verify its signed token in your app, so nothing can sneak in around it:
import { createRemoteJWKSet, jwtVerify } from 'jose'
const JWKS = createRemoteJWKSet(new URL(`${env.TEAM_DOMAIN}/cdn-cgi/access/certs`))
const token = request.headers.get('cf-access-jwt-assertion')
if (!token) return new Response('Forbidden', { status: 403 })
// throws if the signature, issuer or audience is wrong
await jwtVerify(token, JWKS, { issuer: env.TEAM_DOMAIN, audience: env.POLICY_AUD })
9. Receive email and run code on it
Email Routing forwards hello@yourdomain.com to your existing inbox, with unlimited inbound mail on the free plan. Or hand the message to a Worker:
async email(message, env) {
if (message.from.endsWith('@spam.example')) {
return message.setReject('Sender not accepted')
}
await env.DB.prepare('INSERT INTO inbox (sender, subject) VALUES (?, ?)')
.bind(message.from, message.headers.get('subject'))
.run()
}
Locally, the signup mail was stored in D1 and the spam sender got Worker rejected email with the following reason: Sender not accepted. Support ticket intake and "email to create a task" are a few lines away. Sending mail on the free plan works only to addresses you have verified.
10. Automate a browser and watch your site
- Browser Run gives you headless browsers for screenshots, PDFs and pages that need JavaScript to render. Free: 10 browser minutes a day, 3 concurrent browsers.
- Web Analytics measures traffic and page performance in a privacy-focused way, on all plans.
- Workers Logs keeps 200,000 log events a day for 3 days.
What changed in October 2026
In an update on 2 October, Cloudflare committed to introducing no new Enterprise-only features (with exceptions such as Cloudflare for Government) and moved more of the existing ones down:
- Logpush, which ships your logs to your own storage or tools, is now self-serve for Free, Pro and Business. It is usage-based: pricing lists 25 GB a month included for internal destinations and 25 GB for external ones. Exporting Workers trace logs still needs the Workers Paid plan.
- Logpush Transformers (filter and redact logs with SQL) are becoming generally available, and Custom Dashboards are open to all customers.
- The same post highlights Terraform support for all customers and higher limits across several developer products.
Where free stops
- On the Workers Free plan, daily allowances reset at 00:00 UTC (5:30 AM in India). Go over a Workers, D1, KV or Durable Objects limit and operations fail with errors. Design for that.
- R2 and Logpush can bill you beyond their included amounts.
- Containers require the Workers Paid plan, which starts at $5 a month.
- 10 ms of CPU rules out heavy computation on the free plan.
Free tier cheat sheet
| Product | Use it for | Free allowance |
|---|---|---|
| Workers | APIs, backends | 100,000 requests/day |
| Static Assets | Frontends | Static requests free and unlimited |
| D1 | SQL data | 5M rows read, 100k written/day, 5 GB |
| KV | Config, cache | 100k reads, 1k writes/day, 1 GB |
| Durable Objects | Coordination, realtime | 100k requests/day, 5 GB |
| R2 | Files | 10 GB/month, free egress |
| Queues | Background jobs | 10k operations/day |
| Workflows | Multi-step jobs | 3,000 steps/day |
| Hyperdrive | Your Postgres or MySQL | 100k queries/day |
| Workers AI | Models | 10,000 Neurons/day |
| Vectorize | Embeddings | 5M stored dimensions |
| Turnstile | Bot checks | Unlimited challenges |
| Access | Internal tool login | Up to 50 users |
| Email Routing | Inbound email | Unlimited inbound |
| Browser Run | Headless browser | 10 minutes/day |
Try it this weekend
- Deploy a Vite app with Static Assets.
- Add
/api/feedback, store it in D1, and checkrows_read. - Protect the form with Turnstile and verify the token.
- Send a notification through a Queue.
- Put your admin page behind Access.
You can do steps 2 and 4 entirely on your laptop with npx wrangler dev before creating an account.
The takeaway
Cloudflare is not a CAPTCHA company that also does some other things. It is a place to build and protect whole applications, with a free tier generous enough to learn on and ship real side projects.
I would love for more developers to know that. If someone still thinks Cloudflare is just a checkbox, send them this, then show them what you built.
I’m Mohammad Palla, founding engineer at Vaani AI Research — I build voice AI agents, public APIs/SDKs, and developer platforms. I write about voice AI, RAG, performance and web infra in this dev log. Say hi: mohammadpalla24@gmail.com