# Cloudflare Free Reference

This reference is for planning experiments in this workspace. It focuses on products and stack choices that can be used on Cloudflare's free ecosystem or that include a free allowance on the Workers Free plan.

## Important corrections to common assumptions

- `Vectorize` is not currently on the Workers Free plan. The official pricing page shows it on the Workers paid plan only.
- `Workers AI` is available with free allowances/credits and is commonly used for experimentation, but the quota model changes over time and is not the same as a fixed storage-style limit.
- `Pages` hosting has free static hosting/bandwidth, while `Pages Functions` are billed as Workers and inherit Workers pricing/limits.
- `Durable Objects` are available on the Workers Free plan only with the SQLite storage backend.

## Free-tier products and allowances

### Core platform

| Product         | Free allowance                                                                              | Best use                                                                     |
| --------------- | ------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------- |
| Workers         | 100,000 requests/day, 10 ms CPU/invocation                                                  | API endpoints, routing, glue logic, lightweight background work              |
| Pages           | Free static hosting and unlimited asset bandwidth                                           | Static sites, frontends, docs, demos                                         |
| Pages Functions | Same as Workers billing                                                                     | SSR and server-side routes on Pages                                          |
| Workers KV      | 100,000 reads/day, 1,000 writes/day, 1 GB storage                                           | Feature flags, cached config, session-like data                              |
| Hyperdrive      | 100,000 database queries/day                                                                | Connection pooling and faster access to existing SQL databases               |
| D1              | 5 million rows read/day, 100,000 rows written/day, 5 GB storage total                       | Relational data, logs, small apps, app state                                 |
| Durable Objects | 100,000 requests/day, 13,000 GB-s/day, SQLite backend only                                  | Real-time coordination, strongly consistent state, multiplayer/session logic |
| Queues          | 10,000 operations/day included                                                              | Async job processing, retries, background pipelines                          |
| R2              | 10 GB-month storage, 1 million Class A ops/month, 10 million Class B ops/month, free egress | Files, images, PDFs, media, backups                                          |
| Workers Logs    | 200,000 logs/day, 3 days retention                                                          | Debugging and operational tracing during experiments                         |

### AI and search

| Product    | Free status                                                                                | Best use                                                                     |
| ---------- | ------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------- |
| Workers AI | Free allowances/credits available                                                          | Local inference at the edge, speech-to-text, text generation, classification |
| AI Gateway | Free logged requests are available on the free ecosystem, but limits are account-dependent | Observability, caching, rate limiting, model proxying                        |
| Vectorize  | Paid-plan only                                                                             | Embeddings and vector search                                                 |

### Storage and media-adjacent services

| Product  | Free status                                                           | Notes                                                                    |
| -------- | --------------------------------------------------------------------- | ------------------------------------------------------------------------ |
| R2       | Free tier available                                                   | Zero egress is the main advantage; Standard storage is the free-tier fit |
| Images   | Has free features and/or trial-style usage depending on account state | Use for transforms, optimization, delivery                               |
| Stream   | Not a fixed free-core product                                         | Useful for video experiments, but not a guaranteed free baseline         |
| Realtime | Not a fixed free-core product                                         | Good for audio/video collaboration tests                                 |

## Missing items added from official docs

These are the most important additions beyond the original list:

- `Workers Logs` is included on the free plan and is useful for debugging small experiments.
- `Hyperdrive` has a free allowance and is useful when connecting Workers to existing databases.
- `Durable Objects` should be on the planning list because SQLite-backed objects are free-plan compatible.
- `Pages Functions` should be treated as Workers for pricing and limits.
- `Service bindings` are a capability worth including in architecture planning because they do not add extra request fees between Workers.
- `Containers` exist on the platform, but they are not a free-tier target.

## Tech stacks that work well on Cloudflare

### Full-stack JavaScript and TypeScript

- Next.js with Cloudflare support via adapter/Pages integration
- Remix
- React Router framework mode
- SvelteKit with `@sveltejs/adapter-cloudflare`
- Nuxt with Cloudflare-compatible Nitro presets
- SolidStart
- Qwik
- Analog

### Frontend and static-site stacks

- React + Vite
- Vue + Vite
- Angular
- Preact
- Ember
- Astro
- Gatsby
- Docusaurus
- Eleventy
- Elder.js
- Gridsome
- VitePress
- Hugo
- Jekyll
- MkDocs
- Zola
- Pelican
- Sphinx

### Backend languages and runtimes

- JavaScript
- TypeScript
- Python Workers
- Rust via WebAssembly
- Go via WebAssembly
- C++ via WebAssembly

### Common Cloudflare build patterns

- Static frontend on Pages plus API Worker
- Full-stack framework compiled to Workers or Pages Functions
- Worker plus D1 for relational state
- Worker plus KV for cached edge state
- Worker plus R2 for file/media storage
- Worker plus Queues for async processing
- Worker plus Durable Objects for coordination and real-time state
- Worker plus Hyperdrive for external SQL connections

## Practical starter matrix

| Goal                   | Recommended stack                |
| ---------------------- | -------------------------------- |
| Small demo site        | Pages + plain HTML/CSS/JS        |
| Animated UI experiment | Pages + vanilla JS or React/Vite |
| CRUD app               | Pages + Worker + D1              |
| File upload app        | Pages + Worker + R2              |
| Async processing       | Worker + Queues                  |
| Real-time coordination | Worker + Durable Objects         |
| AI assistant or agent  | Worker + Workers AI + AI Gateway |
| External DB connection | Worker + Hyperdrive              |

## Notes for agents

- Prefer the smallest free-plan compatible stack that can prove the idea.
- Treat quota notes as moving targets and verify before relying on them.
- Keep one experiment per page so failures stay isolated.

## Sources reviewed

- Cloudflare Workers pricing and platform pages
- Cloudflare R2 pricing
- Cloudflare D1 pricing
- Cloudflare developer services overview
