<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud" -->

---
title: Manage Vercel Flags segments with Vercel CLI | daily.dev
description: Vercel Flags segments can now be managed directly from the Vercel CLI using the new `vercel flags segments` command. Segments are the targeting primitives that...
canonical: https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Manage Vercel Flags segments with Vercel CLI | daily.dev
og:description: Vercel Flags segments can now be managed directly from the Vercel CLI using the new `vercel flags segments` command. Segments are the targeting primitives that...
og:url: https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud
og:image: https://api.daily.dev/og/posts/uK88pjCuD.png
og:image:alt: Manage Vercel Flags segments with Vercel CLI
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Manage Vercel Flags segments with Vercel CLI

**[Vercel](https://daily.dev/sources/vercel)** · 1 min read · 6 upvotes · 0 comments

## Summary

Vercel Flags segments can now be managed directly from the Vercel CLI using the new `vercel flags segments` command. Segments are the targeting primitives that control who sees which flag value, composed from `include:`, `exclude:`, and `rule:` tokens. The command supports incremental edits via `--add` and `--remove` flags, or full replacement using `--data` with raw JSON. All segment commands support `--json` output, enabling scripting from CI pipelines, local workflows, and agent-driven pipelines. Update to the latest Vercel CLI version to get started.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://vercel.com/changelog/manage-vercel-flags-segments-with-vercel-cli>

## Questions this post answers

### How do I manage Vercel Flags segments from the command line?

Use the new vercel flags segments command in the Vercel CLI to create and update segments without leaving the terminal. Segment membership is composed of three repeatable tokens: include:, exclude:, and rule:, passed via --add or --remove for incremental edits, or via --data to replace the entire segment definition with raw JSON.

_Developers scripting feature flag rollouts can follow CLI changes like this one on daily.dev._

### How do I add a rule-based condition to a Vercel Flags segment while removing a specific user?

Run vercel flags segments update with a --add rule: token for the new condition and a --remove include: token for the user, in the same command. For example, add rule:user.plan:eq:enterprise while removing include:user.id=user_123, since create and update both accept repeatable include:, exclude:, and rule: tokens.

_Anyone automating flag targeting logic can track CLI capabilities like this via daily.dev._

### Can Vercel Flags CLI commands output JSON for scripting?

Yes, all segment commands in the Vercel CLI support a --json output flag, making them scriptable from CI pipelines, local workflows, and agent-driven automation that needs to inspect or update flag targeting from the terminal.

_Teams building CI-driven flag automation can keep tabs on tooling updates like this through daily.dev._

## Similar posts on daily.dev

- [Vercel Flags is now in public beta](https://daily.dev/posts/vercel-flags-is-now-in-public-beta-ifjoyxyym) · Vercel · 49 upvotes · 2 comments
- [Vercel Flags is now generally available](https://daily.dev/posts/vercel-flags-is-now-generally-available-u3pwl3bta) · Vercel · 46 upvotes · 3 comments
- [Vercel Flags: Platform-native feature flags](https://daily.dev/posts/vercel-flags-platform-native-feature-flags-t5xawik71) · Vercel · 2 upvotes · 0 comments
- [Automate progressive rollouts with Vercel Flags](https://daily.dev/posts/automate-progressive-rollouts-with-vercel-flags-bcllj0obj) · Vercel · 15 upvotes · 1 comments
- [Roll it out, roll it back, never redeploy](https://daily.dev/posts/roll-it-out-roll-it-back-never-redeploy-y5tgv5tlh) · Railway Blog · 1 upvotes · 0 comments

---

Tags: [#cicd](https://daily.dev/tags/cicd), [#cli](https://daily.dev/tags/cli), [#vercel](https://daily.dev/tags/vercel)

[View this post on daily.dev](https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Manage Vercel Flags segments with Vercel CLI","url":"https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud"},"datePublished":"2026-07-03T10:02:06.107Z","dateModified":"2026-09-14T08:38:42.489Z","description":"Vercel Flags segments can now be managed directly from the Vercel CLI using the new `vercel flags segments` command. Segments are the targeting primitives that...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/ba65459b97e82bfb8c405846d9277900?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/ba65459b97e82bfb8c405846d9277900?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Vercel","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Vercel","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/04cca7235cf84db092f24b7ba427b3e1","url":"https://daily.dev/sources/vercel"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":6},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"cicd,cli,vercel","timeRequired":"PT1M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Vercel","item":"https://daily.dev/sources/vercel"},{"@type":"ListItem","position":3,"name":"Manage Vercel Flags segments with Vercel CLI"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/manage-vercel-flags-segments-with-vercel-cli-uk88pjcud#faq","mainEntity":[{"@type":"Question","name":"How do I manage Vercel Flags segments from the command line?","acceptedAnswer":{"@type":"Answer","text":"Use the new vercel flags segments command in the Vercel CLI to create and update segments without leaving the terminal. Segment membership is composed of three repeatable tokens: include:, exclude:, and rule:, passed via --add or --remove for incremental edits, or via --data to replace the entire segment definition with raw JSON. Developers scripting feature flag rollouts can follow CLI changes like this one on daily.dev."}},{"@type":"Question","name":"How do I add a rule-based condition to a Vercel Flags segment while removing a specific user?","acceptedAnswer":{"@type":"Answer","text":"Run vercel flags segments update with a --add rule: token for the new condition and a --remove include: token for the user, in the same command. For example, add rule:user.plan:eq:enterprise while removing include:user.id=user_123, since create and update both accept repeatable include:, exclude:, and rule: tokens. Anyone automating flag targeting logic can track CLI capabilities like this via daily.dev."}},{"@type":"Question","name":"Can Vercel Flags CLI commands output JSON for scripting?","acceptedAnswer":{"@type":"Answer","text":"Yes, all segment commands in the Vercel CLI support a --json output flag, making them scriptable from CI pipelines, local workflows, and agent-driven automation that needs to inspect or update flag targeting from the terminal. Teams building CI-driven flag automation can keep tabs on tooling updates like this through daily.dev."}}]}
```

