Skip to content

Claim deployments (temporary accounts)

Diagram showing an AI agent deploying, verifying, and redeploying a Worker to a temporary account, then claiming it after authentication and moving it to a permanent account

Use claim deployments when an AI agent needs to deploy a Worker without an existing Cloudflare account, and without needing to first log in and authorize the Wrangler CLI.

wrangler deploy --temporary creates or reuses a temporary preview account, deploys your Worker to a workers.dev URL, and prints a claim URL. Claim the temporary preview account within 60 minutes to keep the deployment and the Cloudflare resources created for it.

Use cases

  • AI-generated deployments
  • Background agent sessions
  • Prototyping new ideas quickly on a fresh Cloudflare account
  • First-time Workers evaluations

For production and continuous integration and continuous deployment (CI/CD), use a permanent Cloudflare account with wrangler login or a Cloudflare API token. Do not use --temporary when the Wrangler CLI is already authenticated.

Get started

Use the following flow to let an AI agent discover and use temporary deploys. This flow requires Wrangler 4.102.0 or later. The agent starts with the normal deploy command. If no Cloudflare credentials are available, the Wrangler CLI tells it to rerun with --temporary.

  1. Install or update the Wrangler CLI to version 4.102.0 or later.

    For installation instructions, refer to Install and update.

  2. Give your AI agent a deploy prompt.

    For example:

    Make a very simple Hello World Cloudflare Worker in TypeScript and deploy it using the Wrangler CLI. Do not ask me questions.
  3. The agent will run the deploy.

    If the Wrangler CLI has no credentials, it prints output similar to the following:

    To continue without logging in, rerun this command with `--temporary`.
    Wrangler will use a temporary account and print a claim URL.

    This output lets the agent discover the --temporary flag without you explicitly telling it to use the flag.

  4. The agent will rerun the deploy with --temporary:

    npx wrangler deploy --temporary

    The CLI prints output similar to the following:

    Continuing means you accept Cloudflare's Terms of Service (https://www.cloudflare.com/terms/) and Privacy Policy (https://www.cloudflare.com/privacypolicy/).
    Temporary account ready:
    Account: example-name (created)
    Claim within: 60 minutes
    Claim URL: https://dash.cloudflare.com/claim-preview?claimToken=<TOKEN>
    Uploaded example-worker
    Deployed example-worker triggers
    https://example-worker.example-name.workers.dev
  5. The agent can redeploy before you claim the temporary preview account.

    The Wrangler CLI caches the temporary preview account and reuses it while both the account and claim URL are valid. The output shows whether the account was created or reused. The CLI clears the cached temporary preview account when you run wrangler login or wrangler logout.

    You can keep deploying changes with wrangler deploy --temporary while the temporary preview account remains active. If you do not claim the temporary preview account within 60 minutes, Cloudflare deletes it and its deployments.

Claim the deployment

To keep the deployment, open the claim URL within 60 minutes. Sign in to Cloudflare or create an account, then follow the dashboard prompts to claim the temporary preview account.

After you claim the temporary preview account, the Worker and Cloudflare resources created in that account remain available to you. To continue using the Wrangler CLI with the claimed account, run wrangler login, then deploy without --temporary.

Supported products and limits

Temporary preview accounts currently support the following Cloudflare products and limits only. Cloudflare will add support for more products over time.

Supported product or resourceTemporary preview account limit
WorkersDeployments on workers.dev
Workers Static AssetsUp to 1,000 files, with each asset up to 5 MiB
Workers KVCommands that use temporary credentials
D1One database, with up to 100 MB per database and 100 MB total
HyperdriveUp to two database configurations and 10 connections
QueuesUp to 10 queues
SSL/TLS certificatesCommands that use temporary credentials

Limits

  • Temporary preview accounts expire after 60 minutes if they are not claimed.
  • Before the Wrangler CLI creates a temporary preview account, Cloudflare requires a proof-of-work check. The CLI handles this automatically. It can add a short delay, but does not require extra input.
  • Cloudflare limits how quickly you can create temporary preview accounts. If the Wrangler CLI cannot create an account because too many temporary preview accounts were requested too quickly, wait before retrying or authenticate the CLI with a permanent Cloudflare account.
  • --temporary is only for unauthenticated use. If the Wrangler CLI can already use OAuth, CLOUDFLARE_API_TOKEN, or a global API key, --temporary returns an error.
  • --temporary is not a global flag. It is available only on commands that can use the short-lived temporary preview account token.
  • Claim URLs grant ownership of the temporary preview account. Treat them as sensitive.
  • Cloudflare applies additional abuse prevention checks to temporary preview accounts.