The two types of deployment on the Vercel platform are: preview and production.
Preview deployments are the default for all deployments. Each time you push to a branch or make a deployment using the
vercel command, this is a preview deployment.
By making a preview deployment, the preview URL will be updated to reflect that of the latest deployment made.
If you request a preview URL, the
X-Robots-Tag HTTP header will be set as
noindex. This ensures that preview URLs will not be indexed by search engines such as Google. The only exception to this behavior exists when a custom domain is assigned to a preview branch. A custom domain assigned to a preview deployment will not set the
X-Robots-Tag header with the value
noindex. Learn more about
X-Robots-Tag by visiting Google Search Reference.
To turn off the Preview Builds, you can use the "Ignore Build Step" option. Using this command, you can tell Vercel only to build your
main branch and ignore all other branches. If the command returns "0", the build will be skipped. If, however, a code "1" or greater is returned, then a new deployment will be built.
Production deployments are made in two different circumstances. Each time you merge to the Production Branch (commonly
main) or make a deployment using the
vercel --prod command, this is a production deployment.
By making a production deployment, the production domain(s) will be updated to reflect that of the latest deployment.
The production domain(s) are defined from the Domains tab of a Project on the Vercel Dashboard.
For both Preview and Production environments, you can define Environment Variables as key-value pairs which are configured outside your source code. These variables are available to your source code during the build process.
At any point, you can change the value of the Environment Variables. But make sure to Redeploy your project to update the value of these variables.