npx wrangler d1 info my-db

Category: Cloudflare

npx wrangler d1 info my-db

Show D1 database size and state

Reports the database's current size, number of tables, and health state, useful before deciding to back up or restore. Add --json for script consumption. Size creeping up is a sign to prune old rows.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.