1 Choose user token or account token
In the Cloudflare dashboard, open My Profile -> API Tokens
for a user token, or Manage Account -> Account API Tokens
for an account-owned token. Account-owned tokens are usually the
better fit for long-lived shared setups.
2 Create a custom D1 token
The direct links on this page open Cloudflare's token builder with a
D1 edit token prefilled for BaseDeck. If you create the token
manually, scope it to the target account and grant
D1 Read for browsing or D1 Edit for full
BaseDeck support including approved write SQL.
3 Copy IDs only when you need to pin them
If you leave accountId and databaseId
empty, BaseDeck will discover the accessible accounts and D1
databases automatically. Fill them only when you want one fixed
account or one fixed D1 database.
4 Paste it into BaseDeck
In the Cloudflare D1 connection form, paste the API token, optionally
add the account and database IDs, then click
Test Connection before saving.