system environment variables.md
title: System environment variables product: vercel url: /docs/environment-variables/system-environment-variables canonical_url: "https://vercel.com/docs/environment-variables/system-environment-variables" last_updated: 2026-07-15 type: reference prerequisites: - /docs/environment-variables related: - /docs/skew-protection summary: System environment variables are automatically populated by Vercel, such as the URL of the deployment or the name of the Git branch deployed. install_vercel_plugin: npx plugins add vercel/vercel-plugin
System environment variables
Vercel provides a set of environment variables that are automatically populated by the system, such as the URL of the deployment or the name of the Git branch deployed.
Enable system environment variables
To enable these environment variables to your deployments:
- Navigate to your project on your dashboard.
- Select Environment Variables in the sidebar.
- Select the Enable access to System Environment Variables checkbox.
💡 Note: If you disable this setting, no deployment ID will be made available for supported frameworks (like Next.js) to use, which means Skew Protection will also be disabled.
System environment variables
If you are using a framework for your project, Vercel provides the following prefixed environment variables:
💡 Note: When you choose to enable system environment variables, some React warnings, such as those in a
create-react-appwill display as build errors. For more information on this error, see How do I resolve aprocess.env.CI = trueerror?
VERCEL
Available at: Both build and runtime
An indicator to show that system environment variables have been exposed to your project's Deployments.
VERCEL=1
CI
Available at: Build time
An indicator that the code is running in a Continuous Integration environment.
CI=1
VERCEL_ENV
Available at: Both build and runtime
The environment that the app is deployed and running on. The value can be either production, preview, or development.
VERCEL_ENV=production
VERCEL_TARGET_ENV
Available at: Both build and runtime
The system or custom environment that the app is deployed and running on. The value can be either production, preview, development, or the name of a custom environment.
VERCEL_TARGET_ENV=production
VERCEL_URL
Available at: Both build and runtime
The domain name of the generated deployment URL. Example: *.vercel.app. The value does not include the protocol scheme https://.
Note: This variable cannot be used in conjunction with Standard Deployment Protection. See Migrating to Standard Protection.
VERCEL_URL=my-site.vercel.app
VERCEL_BRANCH_URL
Available at: Both build and runtime
The domain name of the generated Git branch URL. Example: *-git-*.vercel.app. The value does not include the protocol scheme https://.
VERCEL_BRANCH_URL=my-site-git-improve-about-page.vercel.app
VERCEL_PROJECT_PRODUCTION_URL
Available at: Both build and runtime
A production domain name of the project. We select the shortest production custom domain, or vercel.app domain if no custom domain is available. Note, that this is always set, even in preview deployments. This is useful to reliably generate links that point to production such as OG-image URLs. The value does not include the protocol scheme https://.
VERCEL_PROJECT_PRODUCTION_URL=my-site.com
VERCEL_REGION
Available at: Runtime
The ID of the Region where the app is running.
VERCEL_REGION=cdg1
VERCEL_DEPLOYMENT_ID
Available at: Both build and runtime
The unique identifier for the deployment, which can be used to implement Skew Protection.
VERCEL_DEPLOYMENT_ID=dpl_7Gw5ZMBpQA8h9GF832KGp7nwbuh3
VERCEL_PROJECT_ID
Available at: Both build and runtime
The unique identifier for the project.
VERCEL_PROJECT_ID=prj_Rej9WaMNRbffVm34MfDqa4daCEvZzzE
VERCEL_SKEW_PROTECTION_ENABLED
Available at: Both build and runtime
When Skew Protection is enabled in Project Settings, this value is set to 1.
VERCEL_SKEW_PROTECTION_ENABLED=1
VERCEL_AUTOMATION_BYPASS_SECRET
Available at: Both build and runtime
The Protection Bypass for Automation value, if the secret has been generated in the project's Deployment Protection settings.
VERCEL_AUTOMATION_BYPASS_SECRET=secret
VERCEL_OIDC_TOKEN
Available at: Build time
When Secure Backend Access with OpenID Connect (OIDC) Federation is enabled in Project Settings, this value is set to a Vercel-issued OIDC token. At runtime, the token is set to the x-vercel-oidc-token header on your functions' Request object. In local development, you can download the token using the CLI command vercel env pull.
VERCEL_OIDC_TOKEN=secret
VERCEL_HASH_SALT
Available at: Build time
A salt to rotate the filenames of framework-generated content-addressed output. See also Immutable Static Files.
VERCEL_HASH_SALT=1783933175
VERCEL_GIT_PROVIDER
Available at: Both build and runtime
The Git Provider the deployment is triggered from.
VERCEL_GIT_PROVIDER=github
VERCEL_GIT_REPO_SLUG
Available at: Both build and runtime
The origin repository the deployment is triggered from.
VERCEL_GIT_REPO_SLUG=my-site
VERCEL_GIT_REPO_OWNER
Available at: Both build and runtime
The account that owns the repository the deployment is triggered from.
VERCEL_GIT_REPO_OWNER=acme
VERCEL_GIT_REPO_ID
Available at: Both build and runtime
The ID of the repository the deployment is triggered from.
VERCEL_GIT_REPO_ID=117716146
VERCEL_GIT_COMMIT_REF
Available at: Both build and runtime
The git branch of the commit the deployment was triggered by.
VERCEL_GIT_COMMIT_REF=improve-about-page
VERCEL_GIT_COMMIT_SHA
Available at: Both build and runtime
The git SHA of the commit the deployment was triggered by.
VERCEL_GIT_COMMIT_SHA=fa1eade47b73733d6312d5abfad33ce9e4068081
VERCEL_GIT_COMMIT_MESSAGE
Available at: Both build and runtime
The message attached to the commit the deployment was triggered by. The message is truncated if it exceeds 2048 bytes.
VERCEL_GIT_COMMIT_MESSAGE=Update about page
VERCEL_GIT_COMMIT_AUTHOR_LOGIN
Available at: Both build and runtime
The username attached to the author of the commit that the project was deployed by.
VERCEL_GIT_COMMIT_AUTHOR_LOGIN=timmytriangle
VERCEL_GIT_COMMIT_AUTHOR_NAME
Available at: Both build and runtime
The name attached to the author of the commit that the project was deployed by.
VERCEL_GIT_COMMIT_AUTHOR_NAME=Timmy Triangle
VERCEL_GIT_PREVIOUS_SHA
Available at: Build time
The git SHA of the last successful deployment for the project and branch. It's empty on a branch's first deployment, since that branch has no previous successful deployment yet.
Note: This variable is only exposed when an Ignored Build Step is provided.
VERCEL_GIT_PREVIOUS_SHA=fa1eade47b73733d6312d5abfad33ce9e4068080
VERCEL_GIT_PULL_REQUEST_ID
Available at: Both build and runtime
The pull request id the deployment was triggered by. If a deployment is created on a branch before a pull request is made, this value will be an empty string.
VERCEL_GIT_PULL_REQUEST_ID=23