Skills
Skill 22 of 22
Run or troubleshoot Wrangler CLI commands in projects that have a wrangler.jsonc, wrangler.json, or wrangler.toml file, including local development, Previews, deployment, and…
5 minutes · 1,122 words · 7 sections
Install
npx skills add cloudflare/skills --skill wranglernpx skills add cloudflare/skills/plugin marketplace add cloudflare/skillsThe first command installs just this skill, by the name in its SKILL.md; the second installs the whole repository.
Use this skill only when the project has wrangler.jsonc, wrangler.json, or wrangler.toml and no cloudflare.config.ts, or when the user asks for Wrangler. For a new project, a project with cloudflare.config.ts, or a project with no Cloudflare configuration, use the Cloudflare CLI (cf) instead: load the cf-cli skill if it is installed, or follow Use cf with coding agents (opens in a new tab). Do not add Wrangler to those projects.
Use the project’s Wrangler version and retrieve the relevant documentation before writing commands or configuration. CLI flags and configuration fields change; do not rely on memorized examples.
Use the Cloudflare MCP docs tool if available, or fetch the relevant linked page directly. Follow links to the specific command or product involved; avoid loading the entire reference. If a page moves, rediscover it through the Wrangler command index (opens in a new tab) or Cloudflare docs search.
| Task | Source |
|---|---|
| Discover commands and flags, including resource management, deployments, rollback, and diagnostics | Project-local wrangler --help and wrangler <command> --help; command reference (opens in a new tab) |
| Edit config or add a binding | Installed wrangler/config-schema.json (usually under node_modules); configuration reference (opens in a new tab) |
| Deploy a framework application | Framework guides (opens in a new tab); follow the guide for the project’s existing framework and adapter |
| Migrate an application to Workers when requested | Pages to Workers (opens in a new tab); Vercel to Workers (opens in a new tab) |
| Configure staging or production | Environments (opens in a new tab) |
| Set secrets locally, in CI, or on a deployed Worker | Secrets (opens in a new tab) |
| Generate binding and runtime types | TypeScript (opens in a new tab) |
| Run locally or choose a testing approach | Local development (opens in a new tab); testing (opens in a new tab) |
| Choose roles, scopes, or API token permissions for Wrangler | Roles and permissions (opens in a new tab); Workers roles and permissions (opens in a new tab) |
| Create or manage a branch or pull request environment | Previews overview (opens in a new tab); get started (opens in a new tab); configuration (opens in a new tab) |
| Decide whether Preview resources are isolated or shared | Resources and isolation (opens in a new tab), including its current limitations |
| Configure Preview URLs, access, debugging, or CI | Custom domains (opens in a new tab); test and debug (opens in a new tab); examples (opens in a new tab) |
| Choose between Previews, Version URLs, and Wrangler environments | Compare workflows (opens in a new tab) |
| Diagnose authentication or select an account | General commands (opens in a new tab), including whoami; authentication profiles (opens in a new tab) |
| Deploy an unauthenticated prototype | Claim deployments (opens in a new tab) for eligibility, expiry, and claim URL handling; use a permanent account for production or CI |
Use installed help and schema to check whether documented features exist in the project’s version. If a required feature needs an upgrade, make that dependency explicit. If retrieval is unavailable, state the gap and use available local evidence rather than inventing syntax.
wrangler.jsonc for new config. Set a new project’s compatibility date (opens in a new tab) to today; review runtime changes and test when advancing an existing project’s date. Preserve existing project conventions and avoid incidental format migrations.CLOUDFLARE_ENV at dev or build time. Deploy the resulting build; setting an environment at deploy time does not retarget its flattened config. See Vite environments (opens in a new tab).wrangler login OAuth flow does not support granular authorization; use an account-owned API token when granular access is required, and never ask the user to paste its value into chat.secrets.required declaration in the secrets docs.wrangler secret put and secret delete as deployments: they create a version and deploy it immediately. Use the documented wrangler versions secret workflow when the change must be staged.--env value to every Preview command; omitting it targets the top-level Worker.After changing config or bindings in a TypeScript project, regenerate types with the project’s wrangler types command rather than hand-editing generated declarations. Run the relevant existing typecheck or tests.
For deployment changes, use the project’s build workflow and wrangler deploy --dry-run where supported, with the intended config and environment. A successful dry run checks the build and packaging; it does not prove remote resources or runtime behavior work. Use task-specific local or remote checks as appropriate to the requested work.
For Previews, a returned URL does not validate behavior that depends on bindings Wrangler reports as missing. Validate the behavior the user requested, using Preview-specific logs and configuration when needed. Writes to production resources, destructive testing, and deletion of named Previews must match the user’s explicit intent.
Report what changed, the target environment, checks performed, and any unresolved validation gaps. Link the documentation used when the result depends on current command or configuration behavior.
If the user reports that this skill gave incorrect or outdated guidance, or is missing information, read references/skill-feedback.md (opens in a new tab).
Run or troubleshoot Wrangler CLI commands in projects that have a wrangler.jsonc, wrangler.json, or wrangler.toml file, including local development, Previews, deployment, and resource management. For new projects and projects without a Wrangler configuration file, use the cf CLI instead.
The verbatim description from this skill’s front matter — the string an agent matches on to decide whether to load it.
main, last pushed 6 November 2026.SKILL.md, not by matching a directory convention. One layout observed: skills/*/SKILL.md.h1 and no skipped levels:.claude-plugin/marketplace.json by Cloudflare, declaring 1 plugin. It is read for editorial metadata only — never as the skill index, which is always the repository tree./cloudflare/skills.md, and each skill at its own .md URL.1 file · 3 KB
Everything this skill ships beside its prose. All of it is set here, as a subchapter of skill 22.
Documentation the agent loads on demand, rather than up front.