Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@
"vite": "7.3.5",
"vite-tsconfig-paths": "6.1.1",
"vitest": "4.1.9",
"wrangler": "4.106.0",
"wrangler": "4.107.0",
"zod": "4.4.3"
},
"lint-staged": {
Expand Down
86 changes: 43 additions & 43 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

59 changes: 59 additions & 0 deletions src/content/changelog/flagship/2026-07-06-wrangler-commands.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
title: Manage Flagship from the command line with Wrangler
description: Create Flagship apps, bind them to Workers, switch feature flags, and run rollouts with wrangler flagship.
products:
- flagship
date: 2026-07-06
---

**[Wrangler](/workers/wrangler/)** now includes `wrangler flagship`, a command suite for managing [Flagship](/flagship/) apps and feature flags from your terminal.

Create an app and, if you use it from a Worker, add it to your `wrangler.json` or `wrangler.jsonc` file as a binding:

```bash
wrangler flagship apps create "My Worker App" \
--binding FLAGS \
--update-config
```

Then create flags for the behavior you want to control. Flags can be booleans, strings, numbers, or JSON values:

```bash
wrangler flagship flags create <APP_ID> new-checkout

wrangler flagship flags create <APP_ID> checkout-flow \
--variation control=old-checkout \
--variation treatment=new-checkout \
--default control \
--type string
```

After a flag exists, change its default variation or use enable and disable commands as kill switches. Existing targeting rules continue to apply unless you change or clear them explicitly:

```bash
wrangler flagship flags update <APP_ID> checkout-flow --default treatment
wrangler flagship flags disable <APP_ID> checkout-flow
wrangler flagship flags enable <APP_ID> checkout-flow
```

For release workflows, use `rollout`, `split`, and `rules` to change exposure without redeploying your Worker:

```bash
wrangler flagship flags rollout <APP_ID> new-checkout \
--to on \
--percentage 25 \
--by user_id

wrangler flagship flags split <APP_ID> checkout-flow \
--weight control=80 \
--weight treatment=20 \
--by user_id

wrangler flagship flags rules update <APP_ID> checkout-flow \
--priority 1 \
--when "country equals US"
```

These commands can also be used from CI/CD pipelines, scripts, and AI agents to inspect Flagship state, update flag behavior, or roll back changes through Wrangler.

Refer to the [`wrangler flagship` command reference](/flagship/reference/wrangler-commands/) for the full command guide.
1 change: 1 addition & 0 deletions src/content/docs/flagship/get-started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ Refer to the [SDK documentation](/flagship/sdk/) for detailed setup instructions

## Next steps

- Manage flags from the command line with the [`wrangler flagship` commands](/flagship/reference/wrangler-commands/).
- Learn about [targeting rules](/flagship/targeting/) to serve different values based on user attributes.
- Explore the full [binding API reference](/flagship/binding/) for all evaluation methods.
- Read about [percentage rollouts](/flagship/targeting/percentage-rollouts/) for gradual feature releases.
Expand Down
Loading
Loading