Cloudflare Docs
Workers
Workers
Visit Workers on GitHub
Set theme to dark (⇧+D)

Pricing

By default, users have access to the Workers Free plan. The Workers free plan includes limited usage of Workers, Pages Functions and Workers KV. Read more about the Free plan limits.

The Workers Paid plan includes Workers, Pages Functions, Workers KV, and Durable Objects usage for a minimum charge of $5 USD per month for an account. The plan includes increased initial usage allotments, with clear charges for usage that exceeds the base plan.

All included usage is on a monthly basis.

​​ Workers

Free plan Paid Plan - Bundled Paid plan - Unbound
Requests1 100,000 / day 10 million / month, +$0.50/million 1 million / month, + $0.15/million
Duration 10 ms CPU time / invocation 50 ms CPU time / invocation 400,000 GB-s, + $12.50/million GB-s2,3
  1. Requests inbound to your Worker from the Internet are charged on a unit basis for paid plans. Subrequests to external services are not billed on a unit basis, but network time incurred may slightly increase any duration-based billing.

  2. Cloudflare will bill for duration charges based on the higher of your wall time or CPU time, with a multiple of 8 applied to the CPU time to account for the processing power allotted to your Worker. Cloudflare will not bill for wall time duration charges beyond the execution limit given.

  3. Duration billing will charge for the 128 MB of memory allocated to your Worker, regardless of actual usage. If your account has significant traffic to a single Worker, multiple instances of that Worker may run in the same isolate on the same physical machine and share the 128 MB of memory. These Workers are still billed as if they were separate instances, with each being charged as if it had its own 128 MB of memory.

​​ Usage models

Workers are available under two Usage Models: Bundled and Unbound. Usage Models are settings on your Workers that specify the upper limits for how long a Worker can execute. In addition to different limits, Workers on the Bundled Usage Model have usage billing based on requests only, while Workers on Unbound have usage billing based on requests and duration at the rates shown under Pricing.

​​ Default usage model

When an account is first upgraded to the Paid plan, the Unbound plan is used as the default Usage Model. To change your default account-wide Usage Model:

  1. Log in to the Cloudflare dashboard and select your account.
  2. In Account Home, select Workers & Pages.
  3. Find Default Usage Model on the right-side menu > Change.

Cloudflare recommends setting the default to the type of Worker you create the most. Existing Workers will not be impacted when changing the default Usage Model.

You may change the Usage Model for individual Workers without affecting your account-wide default. You can do this through the usage_model key in your wranger.toml file and in the dashboard.

To change the Usage Model for individual Workers:

  1. Log in to the Cloudflare dashboard and select your account.
  2. In Account Home, select Workers & Pages.
  3. In Overview, select your Worker > Settings > Usage Model.

​​ Same features

Worker size, number of Workers, and available memory are not affected by plan type. The Unbound usage model includes a higher number of subrequests. Refer to Limits.

​​ Workers Unbound billing examples

​​ Example 1

If an Unbound Worker executed 1.5 million times and was active a total of 200,000 seconds, the estimated cost in a month would be:

Total = ~$0.08 USD + Minimum $5/mo usage = $5.08

  • (1.5 million requests - included 1 million requests) x $0.15 / 1,000,000 = $0.075
  • (200,000 seconds) * 128 MB / 1 GB = 25,000 GB-seconds
  • (25,000 GB-s - included 400,000 GB-s) x $12.50 / 1,000,000 = $0.00

​​ Example 2

If an Unbound Worker executed 10 million times and was active a total of 6,400,000 seconds the estimated cost in a month would be:

Total = ~$6.35 + Minimum $5/mo usage = $11.35

  • (10 million requests - included 1 million requests) x $0.15 / 1,000,000 requests = $1.35
  • (6,400,000 seconds) * 128 MB / 1 GB = 800,000 GB-seconds
  • (800,000 GB-s - included 400,000 GB-s) x $12.50 / 1,000,000 GB-s = $5.00

​​ Workers Trace Events Logpush

Workers Logpush is only available on the Workers Paid plan.

Paid plan
Requests 1 10 million / month, +$0.05/million

1 Workers Logpush charges for request logs that reach your end destination after applying filtering or sampling.

​​ Workers KV

Free plan1 Paid plan
Read requests 100,000 / day 10 million/month, + $0.50/million
Write requests 1,000 / day 1 million/month, + $5.00/million
Delete requests 1,000 / day 1 million/month, + $5.00/million
List requests 1,000 / day 1 million/month, + $5.00/million
Stored data 1 GB 1 GB, + $0.50/ GB-month
  1. The Workers Free plan includes limited Workers KV usage. All limits reset daily at 00:00 UTC. If you exceed any one of these limits, further operations of that type will fail with an error.

​​ Queues

Queues are only available on the Workers Paid plan. To learn more about Queues pricing, refer to Queues Pricing.

​​ D1

D1 is available on both the Workers Free and Workers Paid plans.

Workers Free Workers Paid
Rows read 5 million / day First 25 billion / month included + $0.001 / million rows
Rows written 100,000 / day First 50 million / month included + $1.00 / million rows
Storage (per GB stored) 1GB (total) First 5GB included + $0.75 / GB-mo

​​ Definitions

  1. Rows read measure how many rows a query reads (scans), regardless of the size of each row. For example, if you have a table with 5000 rows and run a SELECT * FROM table as a full table scan, this would count as 5,000 rows read. A query that filters on an unindexed column may return fewer rows to your Worker, but is still required to read (scan) more rows to determine which subset to return.
  2. Rows written measure how many rows were written to D1 database. A query that INSERT 10 rows into a users table would count as 10 rows written.
  3. Row size or the number of columns in a row does not impact how rows are counted. A row that is 1 KB and a row that is 100 KB both count as one row.
  4. Definining indexes on your table(s) reduce the number of rows read by a query when filtering on that indexed field. For example, if the users table has an index on a timestamp column created_at, the query SELECT * FROM users WHERE created_at > ?1 would only need to read a subset of the table.
  5. Indexes will add an additional written row when writes include the indexed column, as there are two rows written: one to the table itself, and one to the index. The performance benefit of an index and reduction in rows read will, in nearly all cases, offset this additonal write.
  6. Storage is based on gigabytes stored per month, and is based on the sum of all databases in your account. Tables and indexes both count towards storage consumed.
  7. Free limits reset daily at 00:00 UTC. Monthly included limits reset based on your monthly subscription renewal date, which is determined by the day you first subscribed.
  8. There are no data transfer (egress) or throughput (bandwidth) charges for data accessed from D1.

Refer to the D1 documentation to learn more about how D1 is billed.

​​ Durable Objects

Durable Objects are only available on the Workers Paid plan.

Paid plan
Requests 1 million, + $0.15/million
Duration 400,000 GB-s, + $12.50/million GB-s1,2
  1. Duration is billed in wall-clock time as long as the Object is active, but is shared across all requests active on an Object at once. Once your Object finishes responding to all requests, it will stop incurring duration charges. Calling .accept() on a WebSocket in an Object will incur duration charges for the entire time the WebSocket is connected. Prefer using state.acceptWebSocket(), which will stop incurring duration charges once all event handlers finish running.
  2. Duration billing charges for the 128 MB of memory your Durable Object is allocated, regardless of actual usage. If your account creates many instances of a single Durable Object class, Durable Objects may run in the same isolate on the same physical machine and share the 128 MB of memory. These Durable Objects are still billed as if they are allocated a full 128 MB of memory.
  3. Requests including all incoming HTTP requests, WebSocket messages, and alarm invocations. There is no charge for outgoing WebSocket messages, nor for incoming WebSocket protocol pings.
  4. Application level auto-response messages handled by state.setWebSocketAutoResponse() will not incur additional wall-clock time, and so they will not be charged.

​​ Durable Objects billing examples

These examples exclude the costs for the Workers calling the Durable Objects.

​​ Example 1

If a single Durable Object was called by a Worker 1.5 million times, and was active for 1,000,000 seconds in the month, the estimated cost in a month would be:

Total = ~$0.08 USD + Minimum $5/mo usage = $5.08

  • (1.5 million requests - included 1 million requests) x $0.15 / 1,000,000 = $0.075
  • 1,000,000 seconds * 128 MB / 1 GB = 128,000 GB-s
  • (128,000 GB-s - included 400,000 GB-s) x $12.50 / 1,000,000 = $0.00

​​ Example 2

If 100 Durable Objects each had 100 WebSocket connections established to each of them which sent approximately one message a minute for a month, the estimated cost in a month would be, if the messages overlapped so that the Objects were actually active for half the month:

Total = ~$64.65 USD + $202.36 USD + Minimum $5/mo usage = $272.01

  • 100 requests to establish the WebSockets.
  • 100 messages per minute * 100 Durable Objects * 60 minutes * 24 hours * 30 days = 432,000,000 requests
  • (432 million requests - included 1 million requests) x $0.15 / 1,000,000 = $64.65
  • 100 Durable Objects * 60 seconds * 60 minutes * 24 hours * 30 days / 2 = 129,600,000 seconds
  • 129,600,000 seconds * 128 MB / 1 GB = 16,588,800 GB-s
  • (16,588,800 GB-s - included 400,000 GB-s) x $12.50 / 1,000,000 = $202.36

​​ Example 3

If 100 Durable Objects each had a single WebSocket connection established to each of them, which sent one message a second for a month, and the messages overlapped so that the Objects were actually active for the entire month, the estimated cost in a month would be:

Total = ~$38.73 USD + $409.72 USD + Minimum $5/mo usage = $453.45

  • 100 requests to establish the WebSockets.
  • 1 message per second * 100 connections * 60 seconds * 60 minutes * 24 hours * 30 days = 259,200,000 requests
  • (259.2 million requests - included 1 million requests) x $0.15 / 1,000,000 = $38.73
  • 100 Durable Objects * 60 seconds * 60 minutes * 24 hours * 30 days = 259,200,000 seconds
  • 259,200,000 seconds * 128 MB / 1 GB = 33,177,600 GB-s
  • (33,177,600 GB-s - included 400,000 GB-s) x $12.50 / 1,000,000 = $409.72

​​ Durable Objects Transactional Storage API

The Durable Objects Transactional Storage API is only accessible from within Durable Objects. Durable Objects do not have to use the storage API, but if your code does call methods on state.storage, it will incur the following additional charges:

Paid plan
Read request units1,2 1 million, + $0.20/million
Write request units1 1 million, + $1.00/million
Delete requests3 1 million, + $1.00/million
Stored data4 1 GB, + $0.20/ GB-month
  1. A request unit is defined as 4 KB of data read or written. A request that writes or reads more than 4 KB will consume multiple units, for example, a 9 KB write will consume 3 write request units.
  2. List operations are billed by read request units, based on the amount of data examined, for example, a list request that returns a combined 80 KB of keys and values will be billed 20 read request units. A list request that does not return anything is billed for 1 read request unit.
  3. Delete requests are unmetered, for example, deleting a 100 KB value will be charged one delete request.
  4. Objects will be billed for stored data until the data is removed. Once the data is removed, the object will be cleaned up automatically by the system.
  5. Each alarm write is billed as a single write request unit.

Requests that hit the Durable Objects in-memory cache or that use the multi-key versions of get/put/delete methods are billed the same as if they were a normal, individual request for each key.

​​ Service bindings

Service bindings cost the same as any normal Worker. Each invocation is charged as if it is a request from the Internet with one important difference. You will be charged a single billable duration across all Workers triggered by a single incoming request.

For more information on how service bindings work, refer to About Service bindings.

​​ Fine Print

Workers Paid plan is separate from any other Cloudflare plan (Free, Professional, Business) you may have. If you are an Enterprise customer, reach out to your account team to confirm pricing details.

Only requests that hit a Worker will count against your limits and your bill. Since Cloudflare Workers runs before the Cloudflare cache, the caching of a request still incurs costs. See definitions and behavior after a limit is hit in the limits article.