Vercel CLI Supports OIDC Token Exchange: Deploy Without PAT Secrets
Vercel added OIDC token exchange (WIF) for Vercel CLI on Dec 4, 2026. Learn how to replace long-lived PAT secrets in GitHub Actions with short-lived tokens.

Q. Do I still need to store a VERCEL_TOKEN secret to run Vercel CLI in GitHub Actions? No. On December 4, 2026, Vercel officially added OIDC token exchange (Workload Identity Federation, WIF) support for Vercel CLI, letting trusted workloads like GitHub Actions obtain short-lived access tokens per job without storing long-lived Personal Access Tokens (PATs).
⚠️ Accuracy guardrail: This article is based on the official Vercel Changelog (published December 4, 2026) and Vercel CLI OIDC documentation as of December 5, 2026 (KST). The exact TTL of issued short-lived access tokens and the full list of CLI commands that still require a user token were not specified in the official docs and remain unverified.
30-second summary
- Core update: On December 4, 2026, Vercel officially launched OIDC token exchange (WIF) for
Vercel CLI. - Zero stored secrets: In GitHub Actions, adding
id-token: writeandvercel/authenticate-cli-action@v1.0.0issues a short-lived access token without storingVERCEL_TOKEN. - Team-owned permissions: Permissions belong to your team's OIDC policies (
vercel oidc-policies) rather than an individual member's role, so pipelines keep working when team members leave. - Command-based scopes: Policies grant the API scopes required by selected CLI commands and can be restricted by project, repository, branch, or workflow.
- Exception to note: While Vercel recommends migrating CI/CD workflows from PATs to OIDC, some CLI commands—such as managing
vercel oidc-policies—still require a user token.

What changed: From PATs to Workload Identity Federation (WIF)
Previously, running vercel deploy or vercel pull inside GitHub Actions required storing a long-lived PAT as a VERCEL_TOKEN secret. That created leak and rotation overhead, and tied CI/CD pipelines to the individual team member who generated the token.
With Workload Identity Federation (WIF) now supported in Vercel CLI, a CI/CD job presents its provider-issued OIDC token to Vercel's token endpoint (https://api.vercel.com/login/oauth/token) and exchanges it for a short-lived Vercel CLI access token governed by your team's OIDC policy.

| Comparison | Legacy PAT | OIDC Token Exchange (WIF) |
|---|---|---|
| Repository secret | Requires storing long-lived VERCEL_TOKEN |
No secret stored (short-lived per job) |
| Permission owner | Individual team member | Team-level OIDC policy |
| Scope granularity | Hard to restrict per project or command | Scoped by repo, branch, project, and command |
| Audit attribution | Tied to the member's account | Attributed to Vercel CLI on the team |
| Command coverage | Supports all CLI commands | Some commands still require a user token |
Command-based permissions and caveats
When configuring a Vercel CLI OIDC policy, you choose which vercel commands to allow. However, Vercel does not restrict the token strictly to those exact command names—instead, it grants the union of API scopes required by those commands.
For example, enabling a command that needs read-write:deployment also satisfies commands requiring read:deployment. After creating a policy, inspect the "Scopes enabled" list in the dashboard or run the command below to verify the exact permissions granted:
vercel oidc-policies inspect <policy_id> --json
In addition to vercel-cli, OIDC policies support turborepo-cli (Remote Cache) and vercel-container-registry (image pull/push). Because managing OIDC policies requires a team member's credentials, an OIDC-exchanged token cannot run vercel oidc-policies itself.
3 steps to adopt in GitHub Actions
If you are already automating Vercel workflows—as covered in Vercel CI public GitHub support or Vercel Firewall CLI—you only need to swap the authentication step.

Step 1: Create an OIDC policy
Add a policy in the dashboard under Settings → Build and Deployment → OIDC Policies, or run vercel oidc-policies create locally. Every policy must include the aud claim and at least one workload-identifying claim such as repository.
vercel oidc-policies create --name deploy-web \
--issuer https://token.actions.githubusercontent.com \
--claim aud=https://github.com/acme --claim repository=acme/web \
--command deploy --command "env pull (production)" \
--project web
Step 2: Store team and project IDs as Variables
Add your canonical team ID (team_...) as VERCEL_ORG_ID and project ID (prj_...) as VERCEL_PROJECT_ID in GitHub Variables (not Secrets). Vercel recommends Variables so GitHub does not censor non-sensitive IDs in workflow logs.
gh variable set VERCEL_ORG_ID --body "team_your-team-id"
gh variable set VERCEL_PROJECT_ID --body "prj_your-project-id"
Step 3: Add authenticate-cli-action to your workflow
Grant id-token: write to the job and run vercel/authenticate-cli-action@v1.0.0 before calling vercel deploy. For non-GitHub CI providers, you can also exchange the token directly via curl against https://api.vercel.com/login/oauth/token (grant_type=urn:ietf:params:oauth:grant-type:token-exchange).
permissions:
contents: read
id-token: write
jobs:
deploy:
runs-on: ubuntu-latest
env:
VERCEL_PROJECT_ID: ${{ vars.VERCEL_PROJECT_ID }}
steps:
- uses: actions/checkout@v5
- name: Authenticate Vercel CLI
uses: vercel/authenticate-cli-action@v1.0.0
with:
team: ${{ vars.VERCEL_ORG_ID }}
- run: npm install --global vercel@latest
- run: vercel deploy
Q. What happens if multiple OIDC policies match the same workflow? The exchange fails with
Multiple OIDC policies matched.Narrow your policy claims (such asref=refs/heads/main) or pass the exactpol_...ID to the action'spolicyinput.
Toris's take
For solo developers and small teams copying VERCEL_TOKEN secrets across multiple GitHub repositories, migrating deployment workflows to OIDC is a clear win. Pairing repository and ref=refs/heads/main claims prevents accidental production deploys or environment variable pulls from unapproved branches.
Before deleting your existing PAT secrets, audit your workflows for any commands that still require a user token, and migrate standard deploy and env pull jobs first.
Sources
Advertisement