Urgent.News

What's breaking now, across thousands of outlets.

Tech

How I keep Cloudflare under $5 (and what quietly runs up your bill)

I run a few sites on Cloudflare's $5 Workers plan. The base plan covers a lot more than people expect. Most of the surprise bills I've read about come from a few products doing far more work than their owners realized. Here's where the money goes. Turn on billing notifications and usage alerts first. A runaway loop should show up as an email, not on your card statement. Workers: the base is…

Cloudflare's $5 Workers plan is surprisingly generous, covering a lot more than most people assume. However, many users receive surprise bills due to their applications consuming more resources than they realize. To avoid these unexpected charges, enable billing notifications and usage alerts immediately.

Workers provide 10 million requests and 30 million CPU milliseconds per month, with an additional $0.30 per million requests and $0.02 per million CPU milliseconds beyond that. However, bandwidth is not charged.

Serve static files directly as static assets to take advantage of their free and unlimited usage. Routing them through Workers incurs request and CPU charges. Cache non-changing responses to avoid Worker execution, as cache hits count as requests but skip CPU time.

Blocking bots before they reach your code reduces costs by preventing unnecessary Worker operations. Queue operations cost three operations per message (write, read, delete), with a monthly limit of 1 million operations in the Paid plan. Batching doesn't lower the count, and retries incur additional costs.

KV storage charges $0.50 per million reads and $5 per million writes after the included allowance. Writes are the most expensive part, so keep them out of hot paths by batching updates or using D1 or durable objects. R2 storage is inexpensive, but calling HeadObject or ListObjects excessively can become costly. D1 charges for rows scanned, not returned, so index columns frequently filtered on.

Durable Objects have free idle time but charge for active usage. WebSocket connections incur costs, as do pending I/O operations and idle hibernatable objects.

Workers AI offers 10,000 Neurons per day for free, with additional Neuron costs starting at $0.011 per 1,000. Input and output token costs vary by model. Cache results and limit model usage to avoid wastage. Vectorization costs scale with the number of vectors and dimensions stored. Queries are free if not run, so plan accordingly. Browsers cost $0.09 per additional hour, with a free monthly allowance of 10 hours. Finally, storage costs apply even if content is never accessed, so regularly delete unused data.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

Why Cursor Decodes JWTs Instead of Verifying Them (CWE-347)

TL;DR AI editors regularly write auth middleware that calls jwt.decode() where it needs jwt.verify() , so the token's signature is never checked.

  • Cursor developers use jwt.decode() instead of jwt.verify() for authentication middleware.
  • Switching to jose library and verifying signatures resolves the CWE-347 vulnerability.

Why my Mac memory app doesn't try to empty your RAM

Most Mac cleaners show you a big number and offer to make it smaller. That number is usually cached memory, which macOS is putting to good use, and shrinking it makes your Mac slower, not faster.

  • Boost clarifies "free memory" on macOS, unlike Windows' EmptyWorkingSet.
  • macOS kernel compresses idle pages before swapping, Boost captures and reports usage.
  • Boost offers aggressive "Pause" feature to freeze apps, preserving state without CPU usage.

More from Saturday 10 October →