Skip to main content

D1 Limits & Pricing

D1 is billed by rows read, rows written, and total account storage. Included storage is account-wide, while maximum database size is a separate per-database limit.

Included Usage

MetricFree PlanWorkers Paid
Rows read5M / day25B / month included, then $0.001 / million
Rows written100K / day50M / month included, then $1.00 / million
Storage5 GB total / accountFirst 5 GB included / account, then $0.75 / GB-month

Limits That Matter

LimitFree PlanWorkers Paid
Maximum database size500 MB / database10 GB / database
Queries per Worker invocation501,000
Simultaneous open connections per Worker invocation66
Maximum columns per table100100
Maximum row or BLOB size2 MB2 MB
Maximum SQL statement length100 KB100 KB

Consistency and Read Replication

  • D1 queries continue to run on the primary database unless you explicitly use the Sessions API.
  • Read replication is opt-in. When enabled, Sessions API provides sequential consistency within a session.
  • withSession() defaults to first-unconstrained, so use first-primary when the first query must start from the freshest primary state.
Sources

Pricing and limits follow Cloudflare's official D1 pricing, D1 limits, read replication, and D1 Worker API docs.