ampliflare
← TIL
TIL

Cloudflare Workers bills CPU time, not wall-clock time

cloudflare workers performance

The Workers free tier gives you 10 ms of CPU time per request — not 10 ms of elapsed time. If your Worker spends 8 ms waiting on a fetch() call to an external API, that wait doesn’t count toward your limit at all.

This matters a lot in practice. A Worker that fans out three parallel fetch() calls might take 300 ms wall-clock but only burn 3 ms of CPU. You can build surprisingly chatty orchestration logic and stay well within free-tier limits.

The flip side: CPU-heavy work (JSON parsing large payloads, crypto, tight loops) burns budget fast. Keep that logic lean and push heavy computation to a Durable Object or a queue if needed.

You can inspect actual CPU time in the dashboard under Workers → Metrics → CPU time. It’s also available in Logpush via the cpuTime field if you want to alert on it.