What it does
D1 is Cloudflare's managed database service with SQLite SQL semantics and access through Workers, Pages, and an HTTP API. Developers can create databases, define schemas, import data, and run queries from an application or the Wrangler command-line tool. D1 is designed for applications deployed in Cloudflare's platform rather than as a database server that a team installs on its own machines.
Bind a database to an application Worker
Cloudflare's getting-started guide walks through creating a Worker, creating a D1 database, binding the database to that Worker, and running a query from application code. It then covers deploying the application and offers Wrangler-based local development as an optional step. The same guide explains how to populate the database and issue SQL queries, so a useful first project is a small Worker endpoint that writes and reads one application record. The sequence is documented only; no Cloudflare account or test deployment was created here.
D1 uses SQLite's SQL semantics and can be queried from Workers or Pages, with a separate HTTP API documented as another access path. That makes it a candidate for application data kept close to a Cloudflare-hosted app, but teams should check their query patterns and required SQL behavior against D1's documentation instead of assuming it is interchangeable with every SQLite deployment.
Usage and plan fit
The official overview lists D1 on Free and Paid Cloudflare plans. Its pricing documentation describes billing in terms of query activity and storage, with included allowances and charges that vary by plan. Workload shape matters: a busy query pattern or larger database should be estimated against those published metrics rather than treated as a fixed-price server. The service is managed, so the developer's first operational task is to bind and query it, not install or patch a database process.
Strengths
- The documented onboarding path connects a Worker to a database, adds a schema, runs SQL, and reaches deployment without a separate database host.
- D1 exposes database access through Worker bindings and a documented HTTP API.
- The pricing page distinguishes query and storage metrics and includes a Free plan.
Watch out for
- Its documented application path is centered on Cloudflare Workers and Pages; teams should confirm that the binding and HTTP API model fits other runtimes.
- Costs depend on query activity and storage, so the right plan cannot be chosen without a representative workload estimate.
Best for
- Adding SQL-backed persistence to a Cloudflare Worker or Pages application.
- Prototyping small serverless applications with a usage-based managed database.
- Using Wrangler to develop and query D1 locally before deployment.
Sources
- Overview - Cloudflare D1 docs (Oct 25, 2026)
- Getting started - Cloudflare D1 docs (Oct 25, 2026)
- Pricing - Cloudflare D1 docs (Oct 25, 2026)
