Skip to Content

Project Configuration

Static Configuration with vercel.json

vercel.json

This file should be created in your project's root directory and allows you to set:

Copy page

The vercel.json file lets you configure, and override the default behavior of Vercel from within your project.

schema autocomplete

{


}

Type:string | null

buildCommand

The buildCommand property can be used to override the Build Command in the Project Settings dashboard, and the build script from the package.json file for a given deployment. For more information on the default behavior of the Build Command, visit the Configure a Build - Build Command section.

"$schema":"https://openapi.vercel.sh/vercel.json"

To add autocompletion, type checking, and schema validation to your vercel.json file, add the following to the top of your file:

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"buildCommand":"next build"

}

Type:string

Value:"1.4.x" | "1.x"

The bunVersion property configures your project to use the Bun runtime instead of Node.js. When set, all Vercel Functions and Routing Middleware not using the Edge runtime will run using the specified Bun version.


{

}

"bunVersion":"1.4.x"

When using Next.js with ISR (Incremental Static Regeneration), you must also update your build and dev commands in package.json:

"$schema":"https://openapi.vercel.sh/vercel.json",

{

}

"scripts": {

"dev":"bun run --bun next dev",

To learn more about using Bun with Vercel Functions, see the Bun runtime documentation.

}

Type: Boolean.

cleanUrls

Default Value: false.

"build":"bun run --bun next build"

When set to true, all HTML files and Vercel functions will have their extension removed. When visiting a path that ends with the extension, a 308 response will redirect the client to the extensionless path.

For example, a static file named about.html will be served when visiting the /about path. Visiting /about.html will redirect to /about.

Similarly, a Vercel Function named api/user.go will be served when visiting /api/user. Visiting /api/user.go will redirect to /api/user.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"cleanUrls":true

}


If you are using Next.js and running vercel dev, you will get a 404 error when visiting a route configured with cleanUrls locally. It does however work fine when deployed to Vercel. In the example above, visiting /about locally will give you a 404 with vercel dev but /about will render correctly on Vercel.

crons

Type: Array of cron Object.

  • path - Required - The path to invoke when the cron job is triggered. Must start with /.
  • schedule - Required - The cron schedule expression to use for the cron job.

Used to configure cron jobs for the production deployment of a project.

  • A maximum of string length of 512 for the path value.
  • A maximum of string length of 256 for the schedule value.

{

Digital Marketing

{

"$schema":"https://openapi.vercel.sh/vercel.json",
},
"path":"/api/every-minute",
{

Brand & Design

},

"schedule":"* * * * *"
"path":"/api/every-hour",
"schedule":"0 * * * *"
"path":"/api/every-day",

}

]

{
"schedule":"0 0 * * *"
"crons": [
}

devCommand

This value overrides the Development Command in Project Settings.

Type: string | null

The devCommand property can be used to override the Development Command in the Project Settings dashboard. For more information on the default behavior of the Development Command, visit the Configure a Build - Development Command section.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"devCommand":"next dev"

}


fluid

This value allows you to enable Fluid compute programmatically.

{

Type:boolean | null

"$schema":"https://openapi.vercel.sh/vercel.json",

}

Type:string | null

"fluid":true

Available framework slugs:

This value overrides the Framework in Project Settings.

The fluid property allows you to test Fluid compute on a per-deployment or per  custom environment basis when using branch tracking, without needing to enable Fluid in production.

functions


{

}

"framework":"nextjs"

The framework property can be used to override the Framework Preset in the Project Settings dashboard. The value must be a valid framework slug. For more information on the default behavior of the Framework Preset, visit the Configure a Build - Framework Preset section.

"$schema":"https://openapi.vercel.sh/vercel.json",

api/test.js

A glob pattern that matches the paths of the Vercel functions you would like to customize:

Type:Object of key String and value Object.

  • api/*.js (matches one level e.g. api/hello.js but not api/hello/world.js)
  • api/**/*.ts (matches all levels api/hello.ts and api/hello/world.ts)
  • src/pages/**/* (matches all functions from src/pages)
  • runtime (optional): The npm package name of a Runtime, including its version.
  • memory: Memory cannot be set in vercel.json with Fluid compute enabled. Instead set it in the Functions section in your project dashboard sidebar. See setting default function memory for more information.
  • maxDuration (optional): How long your Vercel Function can run on each request. Set an integer number of seconds between 1 and your plan's maximum limit. See max duration.
  • supportsCancellation (optional): A boolean defining whether your Vercel Function should support request cancellation. This is only available when you're using the Node.js runtime.
  • includeFiles (optional): A glob pattern to match files that should be included in your Vercel Function. If you’re using a Community Runtime, the behavior might vary. Please consult its documentation for more details. (Not supported in Next.js, instead use outputFileTracingIncludes in next.config.js )
  • excludeFiles (optional): A glob pattern to match files that should be excluded from your Vercel Function. If you’re using a Community Runtime, the behavior might vary. Please consult its documentation for more details. (Not supported in Next.js, instead use outputFileTracingExcludes in next.config.js )
  • regions (optional): An array of region identifiers specifying where this specific function should be deployed. This overrides the project-level regions setting for the matched functions. See per-function region configuration for more details.
  • functionFailoverRegions (optional): An array of region identifiers specifying passive regions this specific function can fail over to during an outage. This overrides the project-level functionFailoverRegions setting for the matched functions. Enterprise only. See per-function region configuration for more details.

Description

By default, no configuration is needed to deploy Vercel functions to Vercel.

For all officially supported runtimes, the only requirement is to create an api directory at the root of your project directory, placing your Vercel functions inside.

The functions property cannot be used in combination with builds. Since the latter is a legacy configuration property, we recommend dropping it in favor of the new one.

Because Incremental Static Regeneration (ISR) uses Vercel functions, the same configurations apply. The ISR route can be defined using a glob pattern, and accepts the same properties as when using Vercel functions.

When deployed, each Vercel Function uses your project's default memory and maximum duration. See Vercel Functions limits for plan limits and defaults.

With Fluid compute enabled, set memory in the Functions section of your project dashboard, not in vercel.json. To override the maximum duration for matched functions, add the functions property.

functions property with ISR


{

},

"functions": {

"api/test.js": {

}

}

"api/*.js": {

}

"maxDuration":30

"$schema":"https://openapi.vercel.sh/vercel.json",

{


}

},

"functions": {

"maxDuration":5

"pages/blog/[hello].tsx": {

"src/pages/isr/**/*": {

}

}

"$schema":"https://openapi.vercel.sh/vercel.json",

You can set regions and functionFailoverRegions on individual functions to override the project-level defaults. This is useful when different functions need to run in different regions, for example when they access different data sources.

{


"functions": {

},

"api/eu-data.js": {

"regions": ["cdg1"],

"regions": ["iad1"],

"functionFailoverRegions": ["lhr1"]

}

}

"api/us-data.js": {

}

"regions": ["sfo1","iad1"],

"functionFailoverRegions": ["pdx1"]

For more information on Runtimes, see the Runtimes documentation:


{

"functions": {

"api/test.php": {

"runtime":"vercel-php@0.5.2"

}

To use a runtime that is not officially supported, you can add a runtime property to the definition:

}

Type:Array of header Object.

}

"$schema":"https://openapi.vercel.sh/vercel.json",

Valid values: a list of header definitions.

In the example above, the api/test.php Vercel Function does not use one of the officially supported runtimes. In turn, a runtime property was added to invoke the vercel-php community runtime.

"headers": [

"source":"/service-worker.js",

"source":"/(.*)",

"value":"public, max-age=0, must-revalidate"

"headers": [
},
"value":"nosniff"

"value":"1; mode=block"

"key":"X-Content-Type-Options",

"value":"DENY"
"headers": [
},
"key":"authorized"

"source":"/:path*",

"key":"X-XSS-Protection",

"has": [
"type":"query",
"value":"true"
"headers": [

Property

source

Description

This example configures custom response headers for static files, Vercel functions, and a wildcard that matches all routes.

Header object definition

A pattern that matches each incoming pathname (excluding querystring).

has

missing

headers

An optional array of missing objects with the type, key and value properties. Used for conditional path matching based on the absence of specified properties.

A non-empty array of key/value pairs representing each response header.

An optional array of has objects with the type, key and value properties. Used for conditional path matching based on the presence of specified properties.

Property

type

Type

String

Description

Must be either header, cookie, host, or query. The type property only applies to request headers sent by clients, not response headers sent by your functions or backends.

key

value

String

String or Object or undefined

The key from the selected type to match against. For example, if the type is header and the key is X-Custom-Header, we will match against the X-Custom-Header header key.

The value to check for, if undefined any value will match. A regex like string can be used to capture a specific part of the value. For example, if the value first-(?.*) is used for first-second then second will be usable in the destination with :paramName. If an object is provided, it will match when all conditions are met for its fields below.

If value is an object, it has one or more of the following fields:

Condition

Check for inclusion in the array

neq

inc suf

ninc

Start Now
  • re
  • gt
  • gte
  • lt

String (optional)

String (optional) pre

Array (optional)

Start Now
  • String (optional)
  • Number (optional)
  • Number (optional)
  • Number (optional)

Type

Check for prefix Description

Check for non-inclusion in the array

Contact Us
  • Check for a regex match
  • Check for greater than
  • Check for greater than or equal to
  • Check for less than

This example demonstrates using the expressive value object to append the header x-authorized: true if the X-Custom-Header request header's value is prefixed by valid and ends with value.

{

"key":"X-Custom-Header",

"source":"/:path*",

{

"pre":"valid",
"has": [
"type":"header",

"key":"x-authorized",

}

"suf":"value"
"headers": [
"value": {
"value":"true"

],

]

{
}
"headers": [
}

Learn more about headers on Vercel and see limitations.

ignoreCommand

This value overrides the Ignored Build Step in Project Settings.

Type: string | null

This ignoreCommand property will override the Command for Ignoring the Build Step for a given deployment. When the command exits with code 1, the build will continue. When the command exits with 0, the build is ignored. For more information on the default behavior of the Ignore Command, visit the Ignored Build Step section.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"ignoreCommand":"git diff --quiet HEAD^ HEAD ./"

}

{

Type:string | null

The installCommand property can be used to override the Install Command in the Project Settings dashboard for a given deployment. This setting is useful for trying out a new package manager for the project. An empty string value will cause the Install Command to be skipped. For more information on the default behavior of the install command visit the Configure a Build - Install Command section.

Value definition

This value overrides the Install Command in Project Settings.

}

images

"installCommand":"npm install"

Type: Object

"$schema":"https://openapi.vercel.sh/vercel.json",

The images property defines the behavior of Vercel's native Image Optimization API, which allows on-demand optimization of images at runtime.

  • sizes - Required - Array of allowed image widths. The Image Optimization API will return an error if the w parameter is not defined in this list.
  • localPatterns - Allow-list of local image paths which can be used with the Image Optimization API.
  • remotePatterns - Allow-list of external domains which can be used with the Image Optimization API.
  • minimumCacheTTL - Cache duration (in seconds) for the optimized images.
  • qualities - Array of allowed image qualities. The Image Optimization API will return an error if the q parameter is not defined in this list.
  • formats - Supported output image formats. Allowed values are either "image/avif" and/or "image/webp".
  • dangerouslyAllowSVG - Allow SVG input image URLs. This is disabled by default for security purposes.
  • contentSecurityPolicy - Specifies the Content Security Policy of the optimized images.
  • contentDispositionType - Specifies the value of the "Content-Disposition" response header. Allowed values are "inline" or "attachment".

"sizes": [256,640,1080,2048,3840],

"localPatterns": [{

"dangerouslyAllowSVG":false,

"images": {
}],
"hostname":"example.com",
{

"remotePatterns": [

"contentDispositionType":"inline"

"protocol":"https",
"search":""
],
"qualities": [25,50,75],

"minimumCacheTTL":60,

"contentSecurityPolicy":"script-src 'none'; frame-src 'none'; sandbox;",

"search":"?v=1"
}
"port":"",
"formats": ["image/webp"],

outputDirectory

This value overrides the Output Directory in Project Settings.

Type: string | null

The outputDirectory property can be used to override the Output Directory in the Project Settings dashboard for a given deployment.

In the following example, the deployment will look for the build directory rather than the default public or . root directory. For more information on the default behavior of the Output Directory see the Configure a Build - Output Directory section. The following example is a vercel.json file that overrides the outputDirectory to build:

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"outputDirectory":"build"

}

  • entrypoint (required): The path to your Routing Middleware file, relative to your project root. Must end in .js or .ts, must reference an existing file, and can live in a subdirectory such as src/proxy.ts.
  • matcher (optional): A path matcher starting with /, or an array of path matchers starting with /, that defines which requests run your Routing Middleware. See matcher config for the supported syntax.

You can reach our customer support team by emailing info@yourcompany.example.com, calling +1 555-555-5556, or using the live chat on our website. Our dedicated team is available 24/7 to assist with any inquiries or issues.

We’re committed to providing prompt and effective solutions to ensure your satisfaction.

We offer a 30-day return policy for all products. Items must be in their original condition, unused, and include the receipt or proof of purchase. Refunds are processed within 5-7 business days of receiving the returned item.

"proxy": {


{

}

"entrypoint":"proxy.ts",

"matcher":"/api/:func*"

"$schema":"https://openapi.vercel.sh/vercel.json",

The following configuration builds proxy.ts as your Routing Middleware and runs it on requests under /api:

}

}

Your entrypoint exports the handler as a default export:

exportdefaultfunctionproxy(request:Request) {

returnnewResponse('Hello from your Routing Middleware!');

exportdefaultfunctionproxy(request) {

returnnewResponse('Hello from your Routing Middleware!');

}


Runtime

An entrypoint configured through proxy runs on the Node.js runtime.

A middleware.ts file that sets runtime: 'nodejs' in its exported config behaves the same as "proxy": { "entrypoint": "middleware.ts" }.

Setting the matcher

You can set either proxy.matcher in vercel.json, or export a config object with a matcher property from your entrypoint.

The matcher accepts a single path or an array of paths:

"proxy": {

"$schema":"https://openapi.vercel.sh/vercel.json",

"matcher": ["/about/:path*","/dashboard/:path*"]

}

{

"entrypoint":"src/proxy.ts",

}

{


},

}

"proxy": {

"functions": {

"entrypoint":"proxy.ts"

"proxy.ts": {

}

}

Type:Array of redirect Object.

Valid values: a list of redirect definitions.

"maxDuration":10

"$schema":"https://openapi.vercel.sh/vercel.json",

Redirects examples

Enhancing Security for Redirects and Rewrites guide.

This example redirects requests to the path /me from your site's root to the profile.html file relative to your site's root with a 307 Temporary Redirect:

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"redirects": [

{ "source":"/me","destination":"/profile.html","permanent":false }

]

}


This example redirects requests to the path /me from your site's root to the profile.html file relative to your site's root with a 308 Permanent Redirect:

{


}

]

"redirects": [

"$schema":"https://openapi.vercel.sh/vercel.json",

{ "source":"/me","destination":"/profile.html","permanent":true }

{

]

"redirects": [

}

"$schema":"https://openapi.vercel.sh/vercel.json",

{ "source":"/user","destination":"/api/user","statusCode":301 }

{

{

}

"$schema":"https://openapi.vercel.sh/vercel.json",
"source":"/view-source",
"destination":"https://github.com/vercel/vercel"
{

}

]

"redirects": [
"redirects": [
"$schema":"https://openapi.vercel.sh/vercel.json",

{

]

}
"source":"/(.*)",
"destination":"https://vercel.com/docs"
}

This example uses wildcard path matching to redirect requests to any path (including subdirectories) under /blog/ from your site's root to a corresponding path under /news/ relative to your site's root with a redirect status of 308:

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"source":"/blog/:path*",

]

}

"redirects": [

"destination":"/news/:path*"

This example uses regex path matching to redirect requests to any path under /posts/ that only contain numerical digits from your site's root to a corresponding path under /news/ relative to your site's root with a redirect status of 308:

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"source":"/post/:path(\\d{1,})",

]

}

"redirects": [

"destination":"/news/:path*"

This example redirects requests to any path from your site's root that does not start with /uk/ and has x-vercel-ip-country header value of GB to a corresponding path under /uk/ relative to your site's root with a redirect status of 307:

{

Digital Marketing

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"has": [
"source":"/:path((?!uk/).*)",
{

Brand & Design

}

"type":"header",
"key":"x-vercel-ip-country",
"value":"GB"
"destination":"/uk/:path*",

}

]

],
"permanent":false
"redirects": [
}

Property

source


destination

permanent

Description

An optional boolean to toggle between permanent and temporary redirect (default true). When true, the status code is 308. When false the status code is 307.

A pattern that matches each incoming pathname (excluding querystring).

A location destination defined as an absolute pathname or external URL.

has

missing

statusCode

An optional array of has objects with the type, key and value properties. Used for conditional redirects based on the presence of specified properties.

An optional integer to define the status code of the redirect. Used when you need a value other than 307/308 from permanent, and therefore cannot be used with permanent boolean.

An optional array of missing objects with the type, key and value properties. Used for conditional redirects based on the absence of specified properties.

Property

type

Type

String

Description

Must be either header, cookie, host, or query. The type property only applies to request headers sent by clients, not response headers sent by your functions or backends.

key

value

String

String or Object or undefined

The key from the selected type to match against. For example, if the type is header and the key is X-Custom-Header, we will match against the X-Custom-Header header key.

The value to check for, if undefined any value will match. A regex like string can be used to capture a specific part of the value. For example, if the value first-(?.*) is used for first-second then second will be usable in the destination with :paramName. If an object is provided, it will match when all conditions are met for its fields below.

If value is an object, it has one or more of the following fields:

Condition

Check for inclusion in the array

neq

inc suf

ninc

Start Now
  • re
  • gt
  • gte
  • lt

String (optional)

String (optional) pre

Array (optional)

Start Now
  • String (optional)
  • Number (optional)
  • Number (optional)
  • Number (optional)

Type

Check for prefix Description

Check for non-inclusion in the array

Contact Us
  • Check for a regex match
  • Check for greater than
  • Check for greater than or equal to
  • Check for less than

This example uses the expressive value object to define a route that redirects users with a redirect status of 308 to /end only if the X-Custom-Header header's value is prefixed by valid and ends with value.

{

{

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"has": [
"source":"/start",
"destination":"/end",

"redirects": [

}

"type":"header",
"key":"X-Custom-Header",
"value": {
"pre":"valid",

]

}

"suf":"value"
}
]
}

bulkRedirectsPath

Learn more about redirects on Vercel and see limitations.


CSV

Learn more about bulk redirects on Vercel and see limits and pricing.

Type:string path to a file or folder.

CSV, JSON, and JSONL file formats are supported, and the redirect files can be generated at build time as long as they end up in the location specified by bulkRedirectsPath. This can point to either a single file or a folder containing multiple redirect files.

/source/path,/destination/path,true

The bulkRedirectsPath property can be used to import many thousands of redirects per project. These redirects do not support wildcard or header matching.

source,destination,permanent

/source/path-2,https://destination-site.com/destination/path,true

https://old-domain.com/page,/new-page,true

[

{

},

{
"source":"/source/path",
"destination":"/destination/path",
"permanent":true

Brand & Design

},

"source":"/source/path-2",
"destination":"https://destination-site.com/destination/path",
"permanent":true
"source":"https://old-domain.com/page",

Software Delivery

}

{
"destination":"/new-page",
"permanent":true
]

JSONL

{"source": "/source/path", "destination": "/destination/path", "permanent": true}

{"source": "/source/path-2", "destination": "https://destination-site.com/destination/path", "permanent": true}

{"source": "https://old-domain.com/page", "destination": "/new-page", "permanent": true}


vercel dev when you configure bulkRedirectsPath in vercel.json.

Bulk redirect field definition

destination

A location destination defined as an absolute pathname or external URL. Max 2048 characters.

source

Toggle between permanent ( 308) and temporary ( 307) redirect. Default: false.

Description
Required
Yes
string

permanent

Toggle whether source path matching is case sensitive. Default: false.

Yes
string
statusCode
caseSensitive

preserveQueryParams

Toggle whether to preserve the query string on the redirect. Default: false.

boolean
integer
boolean
boolean

To improve space efficiency, all boolean values can be the single characters t (true) or f (false) while using the CSV format.

regions

This value overrides the Vercel Function Region in Project Settings.

Type: Array of region identifier String.

Valid values: List of regions, defaults to iad1.

You can define the regions where your Vercel functions are executed. Users on Pro and Enterprise can deploy to multiple regions. Hobby plans can select any single region. To learn more, see Configuring Regions.

Function responses can be cached in the requested regions. Selecting a Vercel Function region does not impact static files, which are deployed to every region by default.

"regions": ["sfo1"]

"$schema":"https://openapi.vercel.sh/vercel.json",

}

{

Type:Array of region identifier String.

Set this property to specify the region to which a Vercel Function should fallback when the default region(s) are unavailable.

Valid values: List of regions.


{

}

"functionFailoverRegions": ["iad1","sfo1"]

These regions serve as a fallback to any regions specified in the regions configuration. The region Vercel selects to invoke your function depends on availability and ingress. For instance:

"$schema":"https://openapi.vercel.sh/vercel.json",

You can also set functionFailoverRegions on individual functions using the functions property to override the project-level default. See per-function region configuration for more details.

  • Vercel always attempts to invoke the function in the primary region. If you specify more than one primary region in the regions property, Vercel selects the region geographically closest to the request
  • If all primary regions are unavailable, Vercel automatically fails over to the regions specified in functionFailoverRegions, selecting the region geographically closest to the request
  • The order of the regions in functionFailoverRegions does not matter as Vercel automatically selects the region geographically closest to the request

To learn more about automatic failover for Vercel Functions, see Automatic failover. Vercel Functions using the Edge runtime will automatically failover with no configuration required.

Region failover is supported with Secure Compute, see Region Failover to learn more.


Want to talk to our team?

Schedule Call

This feature is available on the Enterprise plan.

rewrites

Valid values: a list of rewrite definitions.

If cleanUrls is set to true in your project's vercel.json, do not include the file extension in the source or destination path. For example, /about-our-company.html would be /about-our-company

You can reach our customer support team by emailing info@yourcompany.example.com, calling +1 555-555-5556, or using the live chat on our website. Our dedicated team is available 24/7 to assist with any inquiries or issues.

We’re committed to providing prompt and effective solutions to ensure your satisfaction.

We offer a 30-day return policy for all products. Items must be in their original condition, unused, and include the receipt or proof of purchase. Refunds are processed within 5-7 business days of receiving the returned item.

  • This example rewrites requests to the path /about from your site's root to the /about-our-company.html file relative to your site's root:

    {

    "$schema":"https://openapi.vercel.sh/vercel.json",

    "rewrites": [

    { "source":"/about","destination":"/about-our-company.html" }

    ] }
  • This example rewrites all requests to the root path which is often used for a Single Page Application (SPA).

    {

    "$schema":"https://openapi.vercel.sh/vercel.json",

    "rewrites": [{ "source":"/(.*)","destination":"/index.html" }]

    }
  • This example rewrites requests to the paths under /resize with 2 path levels (defined as variables width and height that can be used in the destination value) to the api route /api/sharp relative to your site's root:

    {

    "$schema":"https://openapi.vercel.sh/vercel.json",

    "rewrites": [

    { "source":"/resize/:width/:height","destination":"/api/sharp" }

    ] }
  • This example uses wildcard path matching to rewrite requests to any path (including subdirectories) under /proxy/ from your site's root to a corresponding path under the root of an external site https://example.com/:

    {

    "$schema":"https://openapi.vercel.sh/vercel.json",

    "rewrites": [

    {

    "source":"/proxy/:match*",

    "destination":"https://example.com/:match*"

    } ] }
  • This example rewrites requests to any path from your site's root that does not start with /uk/ and has x-vercel-ip-country header value of GB to a corresponding path under /uk/ relative to your site's root:

    {

    "$schema":"https://openapi.vercel.sh/vercel.json",

    "rewrites": [

    {

    "source":"/:path((?!uk/).*)",

    "has": [

    {

    "type":"header",

    "key":"x-vercel-ip-country",

    "value":"GB"

    } ],

    "destination":"/uk/:path*"

    } ] }
  • This example rewrites requests to the path /dashboard from your site's root that does not have a cookie with key auth_token to the path /login relative to your site's root:

    {

    "$schema":"https://openapi.vercel.sh/vercel.json",

    "rewrites": [

    {

    "source":"/dashboard",

    "missing": [

    {

    "type":"cookie",

    "key":"auth_token"

    } ],

    "destination":"/login"

    } ] }

Property

source

Description

destination

A pattern that matches each incoming pathname (excluding querystring).

A location destination defined as an absolute pathname or external URL.

has

missing

permanent

An optional array of has objects with the type, key and value properties. Used for conditional rewrites based on the presence of specified properties.

A boolean to toggle between permanent and temporary redirect (default true). When true, the status code is 308. When false the status code is 307.

An optional array of missing objects with the type, key and value properties. Used for conditional rewrites based on the absence of specified properties.

Property

type

Type

String

Description

Must be either header, cookie, host, or query. The type property only applies to request headers sent by clients, not response headers sent by your functions or backends.

key

value

String

String or Object or undefined

The key from the selected type to match against. For example, if the type is header and the key is X-Custom-Header, we will match against the X-Custom-Header header key.

The value to check for, if undefined any value will match. A regex like string can be used to capture a specific part of the value. For example, if the value first-(?.*) is used for first-second then second will be usable in the destination with :paramName. If an object is provided, it will match when all conditions are met for its fields below.

If value is an object, it has one or more of the following fields:

Condition

Check for inclusion in the array

neq

inc suf

ninc

Start Now
  • re
  • gt
  • gte
  • lt

String (optional)

String (optional) pre

Array (optional)

Start Now
  • String (optional)
  • Number (optional)
  • Number (optional)
  • Number (optional)

Type

Check for prefix Description

Check for non-inclusion in the array

Contact Us
  • Check for a regex match
  • Check for greater than
  • Check for greater than or equal to
  • Check for less than

This example demonstrates using the expressive value object to define a route that rewrites users to /end only if the X-Custom-Header header's value is prefixed by valid and ends with value.

{

{

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"has": [
"source":"/start",
"destination":"/end",

"rewrites": [

}

"type":"header",
"key":"X-Custom-Header",
"value": {
"pre":"valid",

]

}

"suf":"value"
}
]
}

The source property should NOT be a file because precedence is given to the filesystem prior to rewrites being applied. Instead, you should rename your static file or Vercel Function.

has does not yet work locally while using vercel dev, but does work when deployed.

Learn more about rewrites on Vercel.

routes

The routes property lets you define routing rules using PCRE-compatible regular expressions. You can use routes alongside rewrites, redirects, headers, cleanUrls, and trailingSlash.

For common use cases, use those higher-level properties instead. See Routes vs higher-level properties for guidance on when to use each.

Type: Array of route Object.

Valid values: a list of route definitions.

Route object definition

Property

A PCRE-compatible regular expression that matches each incoming pathname (excluding querystring).

headers

A set of HTTP method types. If you omit this property, the route matches any HTTP method.

Description
String[]
Object
Boolean

continue

A set of headers to apply for responses.

Number
destination
statusCode
Array

mitigate

If true, routing will continue even when the src is matched.

String[]
Array
Object
transforms

Deprecated route properties

The following route properties are deprecated:

Vercel processes routes in the order you define them in the array, so wildcard/catch-all patterns should usually be last.

You can reach our customer support team by emailing info@yourcompany.example.com, calling +1 555-555-5556, or using the live chat on our website. Our dedicated team is available 24/7 to assist with any inquiries or issues.

We’re committed to providing prompt and effective solutions to ensure your satisfaction.

We offer a 30-day return policy for all products. Items must be in their original condition, unused, and include the receipt or proof of purchase. Refunds are processed within 5-7 business days of receiving the returned item.

Property

type

Type

String

Description

Must be either header, cookie, host, or query. The type property only applies to request headers sent by clients, not response headers sent by your functions or backends.

key

value

String

String or Object or undefined

The key from the selected type to match against. For example, if the type is header and the key is X-Custom-Header, we will match against the X-Custom-Header header key.

The value to check for, if undefined any value will match. A regex like string can be used to capture a specific part of the value. For example, if the value first-(?.*) is used for first-second then second will be usable in the destination with :paramName. If an object is provided, it will match when all conditions are met for its fields below.

If value is an object, it has one or more of the following fields:

Condition

Check for inclusion in the array

neq

inc suf

ninc

Start Now
  • re
  • gt
  • gte
  • lt

String (optional)

String (optional) pre

Array (optional)

Start Now
  • String (optional)
  • Number (optional)
  • Number (optional)
  • Number (optional)

Type

Check for prefix Description

Check for non-inclusion in the array

Contact Us
  • Check for a regex match
  • Check for greater than
  • Check for greater than or equal to
  • Check for less than

This example uses the value object to define a route that only rewrites to /end if the X-Custom-Header header's value starts with valid and ends with value:

{

{

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"src":"/start",
"dest":"/end",
"has": [

}

}

"type":"header",
"key":"X-Custom-Header",
"value": {
"pre":"valid",

]

}

"suf":"value"
}
"routes": [
]

This example configures custom routes that map to static files and Vercel functions:

{

{

{ "src":"/.*","dest":"https://my-old-site.com" }

"$schema":"https://openapi.vercel.sh/vercel.json",
"src":"/redirect",
"headers": { "Location":"https://example.com/" }
},

{

},

"src":"/custom-page",
"headers": { "cache-control":"s-maxage=1000" },
"dest":"/index.html"
{ "src":"/api","dest":"/my-api.js" },

{ "src":"/legacy","status":404 },

{ "src":"/users","methods": ["POST"],"dest":"/users-api.js" },

]
}
"status":308,
"routes": [

Property

type


op

target

String

String

Description

Must be request.query, request.headers, response.headers, or request.path. This specifies the scope of what your transforms will apply to.

args

env

Object

String[] or undefined

String or String[] or undefined

A whitelist of environment variable names whose values replace $VAR or ${VAR} references in args at request time. Only variables listed here are available for expansion. A maximum of 64 entries. See using environment variables in transforms.

Transform target object definition

Target is an object with a key property. For the set operation, the transform uses key as the header or query key. For other operations, key acts as a matching condition to determine if the transform should apply.

Property

Type

String or Object

key

Description

It may be a string or an object. If it is an object, it must have one or more of the properties defined in the Transform key object definition below.

Transform key object definition

When the key property is an object, it can contain one or more of the following conditional matching properties:

Property

Check inclusion in an array of values

neq

Check non-inclusion in an array of values

String or Number
String[]
Check equality on a value
String[]

ninc

Check if value is greater than or equal to

String
Description
String
String

gte

Check if value is less than or equal to

Number
Number
Number
Number

Request path transform

The request.path transform overrides the path that the target runtime observes for a request. This is the URL path your Function reads from req.url. It does not change route selection or the destination, and it does not terminate routing. Routing continues after the override, so later routes can still match and rewrite. Adjusting the path and rewriting are separate steps, so you can do both.

Because the path is a single value rather than a named target or key, the only supported op is set, and args must be a single string:

{


{

{

"routes": [

"transforms": [

"src":"/home",

"op":"set",

]

}

}

]

"type":"request.path",

"args":"/new/path"

The args value must follow these rules, otherwise the transform is rejected with an error:

  • It must start with /.
  • It must not be scheme-relative (no leading //host).
  • It must not contain a query string.
  • It must not contain whitespace or control characters. Carriage return and line feed characters are rejected as a request-smuggling guard.

You can use the same substitution support as the other transforms in args:

  • Capture groups from the matched route src: numbered ( $1), named ( $name), and the built-ins $host and $wildcard.
  • Environment variable expansion when the transform declares an env allowlist.

When multiple matching routes set request.path, the transform composes across them and is last-write-wins. A later request.path set overrides an earlier one. The override is included in the CDN cache key, so two requests that differ only by their request.path override are cached as separate entries.

Request path transform in a service

Within a service, a request.path transform in the service's own routes changes the path the service's runtime observes. A top-level rewrite selects which service handles a request, and the service receives the original path. A request.path transform inside the service then rewrites the path its code reads from a request, without changing what was routed.

"services": {

{

{ "source":"/api/(.*)","destination": { "service":"my_backend" } }

"entrypoint":"main:app",
{
"src":"/api/(.*)",
{

"root":"backend/",

]

"my_backend": {
"transforms": [
"routes": [
"type":"request.path",

]

}

},
"op":"set",
"rewrites": [
}

A public request to /api/users is routed to my_backend, and the service's code observes /users. See Services routing for how the path a service sees relates to route selection.

Transform examples

In this example, you remove the incoming request header x-custom-header from all requests and responses to the /home route:

{

{

}

"src":"/home",
{
"key":"x-custom-header"
},

"key":"x-custom-header"

{

"transforms": [
"routes": [
"target": {
"op":"delete",

]

}

}
}
"op":"delete",
"target": {

In this example, you override the incoming query parameter theme to dark for all requests to the /home route, and set if it doesn't already exist:

{

"routes": [

{

"$schema":"https://openapi.vercel.sh/vercel.json",
{
"src":"/home",
"transforms": [

Brand & Design

},

"type":"request.query",
"op":"set",
"key":"theme"
"args":"dark"

}

]

}
]
"target": {
}

In this example, you append multiple values to the incoming request header x-content-type-options for all requests to the /home route:

{

"routes": [

{

"$schema":"https://openapi.vercel.sh/vercel.json",
{
"src":"/home",
"transforms": [

Brand & Design

},

"type":"request.headers",
"op":"append",
"key":"x-content-type-options"
"args": ["nosniff","no-sniff"]

}

]

}
]
"target": {
}

In this example, you delete any header that begins with x-react-router- for all requests to the /home route:

{

{

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"src":"/home",
"transforms": [
}

"routes": [

}

"type":"request.headers",
"op":"delete",
"key": {
"pre":"x-react-router-"

]

}

]
}
"target": {
}

In this example, you rewrite the path the runtime observes using a capture group from the matched src. A request to /articles/42 reaches the same destination, but the Function reads /posts/42 from req.url:

{


{

{

"routes": [

"transforms": [

"src":"/articles/(?[^/]+)",

"op":"set",

]

}

}

]

"type":"request.path",

"args":"/posts/$id"

Our Services

Use the env property on a route to expand environment variables in dest. This example proxies all requests under /api/ to a backend URL stored in the BACKEND_URL environment variable:

In route destinations

You can reference environment variables in route dest values and transform args using $VAR or ${VAR} syntax. Add the variable names to the env array on the route or transform so they're available for expansion at request time. Values come from your project's environment variables.

If a referenced variable isn't set in your project's environment, the $VAR reference stays as a literal string in the output.
{
Using environment variables in routes
}

Brand & Design

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"routes": [
"src":"/api/(.*)",
"dest":"${BACKEND_URL}/api/$1",

]

Use the env property on a transform to expand environment variables in args. This example sets a request header x-api-key to the value of the API_KEY environment variable for all requests to the /api route:

"env": ["BACKEND_URL"]
}
In transforms

{

{

{

"$schema":"https://openapi.vercel.sh/vercel.json",
"src":"/api/(.*)",
"transforms": [
"op":"set",

}

},

"type":"request.headers",
"target": {
"key":"x-api-key"
"args":"$API_KEY",

]

}

"env": ["API_KEY"]
}
"routes": [
]

You can reference multiple environment variables in a single args value. List all referenced variables in the env array:

{

{

{

"$schema":"https://openapi.vercel.sh/vercel.json",
}
"src":"/proxy/(.*)",
"transforms": [

"routes": [

},

"type":"request.headers",
"op":"set",
"key":"authorization"
"args":"Bearer ${AUTH_TOKEN}",

]

}

"env": ["AUTH_TOKEN"]
]
"target": {
}

Our Services

Routes vs higher-level properties

Route parameters

For common use cases like redirects, rewrites, and custom headers, the higher-level rewrites, redirects, headers, cleanUrls, and trailingSlash properties offer a more concise alternative to routes. You can use both in the same configuration.

You can combine transforms with the has and missing properties and the matching conditions in the Transform key object definition.
The following examples show how common routes patterns map to higher-level properties.
With rewrites, named parameters pass through in the query string. The following example is equivalent to the routes usage above, but uses rewrites instead:
{

}

With routes, you use a PCRE-compatible regular expression named group to match the ID and then pass that parameter in the query string. The following example matches a URL like /product/532004 and proxies to /api/product?id=532004:

"$schema":"https://openapi.vercel.sh/vercel.json",
"routes": [{ "src":"/product/(?[^/]+)","dest":"/api/product?id=$id" }]
"$schema":"https://openapi.vercel.sh/vercel.json",

Redirects

With routes, you specify the status code to use a 307 Temporary Redirect. Also, this redirect needs to be defined before other routes. The following example redirects all paths in the posts directory to the blog directory, but keeps the path in the new location:

{
"rewrites": [{ "source":"/product/:id","destination":"/api/product" }]
}

{

{

"routes": [

"$schema":"https://openapi.vercel.sh/vercel.json",

"src":"/posts/(.*)",

}

}

"status":307

]

"headers": { "Location":"/blog/$1" },

Although this Website may be linked to other websites, we are not, directly or indirectly, implying any approval.

With redirects, you disable the permanent property to use a 307 Temporary Redirect. Also, redirects are always processed before rewrites. The following example is equivalent to the routes usage above, but uses redirects instead:

{

{

"redirects": [

"$schema":"https://openapi.vercel.sh/vercel.json",

"source":"/posts/:id",

}

]

"permanent":false

}

"destination":"/blog/:id",

With routes, you use "continue": true to prevent stopping at the first match. The following example adds Cache-Control headers to the favicon and other static assets:

{


{

},

"routes": [

"continue":true

"src":"/favicon.ico",

"headers": { "Cache-Control":"public, max-age=3600" },

{

}

]

"continue":true

"src":"/assets/(.*)",

"headers": { "Cache-Control":"public, max-age=31556952, immutable" },

With headers, this is no longer necessary since that is the default behavior. The following example is equivalent to the routes usage above, but uses headers instead:

{

{

}

"headers": [
{
"source":"/favicon.ico",
},

"source":"/assets/(.*)",

{

"key":"Cache-Control",
"headers": [
]
"key":"Cache-Control",

]

}

{
}
"headers": [
]

Pattern matching

With routes, you need to escape a dot with two backslashes, otherwise it would match any character PCRE-compatible regular expression. The following example matches the literal atom.xml and proxies to /api/rss to dynamically generate RSS:


{

}

With rewrites, the . is not a special character so it does not need to be escaped. The following example is equivalent to the routes usage above, but instead uses rewrites:

"$schema":"https://openapi.vercel.sh/vercel.json",

"routes": [{ "src":"/atom\\.xml","dest":"/api/rss" }]

{

}

"$schema":"https://openapi.vercel.sh/vercel.json",

"rewrites": [{ "source":"/atom.xml","destination":"/api/rss" }]

{

}

"routes": [{ "src":"/(?!maintenance)","dest":"/maintenance" }]

"$schema":"https://openapi.vercel.sh/vercel.json",

With routes, you use PCRE-compatible regular expression negative lookahead. The following example proxies all requests to the /maintenance page except for /maintenance itself to avoid an infinite loop:

With rewrites, the regex needs to be wrapped in a capture group. The following example is equivalent to the routes usage above, but instead uses rewrites:

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"rewrites": [

{ "source":"/((?!maintenance).*)","destination":"/maintenance" }

]

}


Case sensitivity

With routes, the src property is case-insensitive, so multiple request paths with different cases serve the same page, creating duplicate content.

With rewrites / redirects / headers, the source property is case-sensitive so you don't accidentally create duplicate content.

Type: Boolean.

false

trailingSlash

When trailingSlash: false, visiting a path that ends with a forward slash will respond with a 308 status code and redirect to the path without the trailing slash.

Default Value: undefined.

For example, the /about/ path will redirect to /about.

{

}

"trailingSlash":false

"$schema":"https://openapi.vercel.sh/vercel.json",

Although this Website may be linked to other websites, we are not, directly or indirectly, implying any approval.

true

When trailingSlash: true, visiting a path that does not end with a forward slash will respond with a 308 status code and redirect to the path with a trailing slash.

For example, the /about path will redirect to /about/.

However, paths with a file extension will not redirect to a trailing slash.

For example, the /about/styles.css path will not redirect, but the /about/styles path will redirect to /about/styles/.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"trailingSlash":true

}


undefined

When trailingSlash: undefined, visiting a path with or without a trailing slash will not redirect.

For example, both /about and /about/ will serve the same content without redirecting.

This is not recommended because it could lead to search engines indexing two different pages with duplicate content.

public

public property is no longer supported and will cause deployment failures. Remove it from your vercel.json immediately to fix broken deployments.

Remove the "public" key from your vercel.json:

{

"$schema":"https://openapi.vercel.sh/vercel.json"

}

Legacy

Deployments always keep source view and logs view protected behind authentication. The public property had no effect and is no longer accepted by the validator.


name

Type: String.

Limits:

Valid values: string name for the deployment.

Legacy properties are still supported for backwards compatibility, but are deprecated.

The name property has been deprecated in favor of Project Linking, which allows you to link a Vercel project to your local codebase when you run vercel.

  • A maximum length of 52 characters
  • Only lower case alphanumeric characters or hyphens are allowed
  • Cannot begin or end with a hyphen, or contain multiple consecutive hyphens

The prefix for all new deployment instances. Vercel CLI usually generates this field automatically based on the name of the directory. But if you'd like to define it explicitly, this is the way to go.

The defined name is also used to organize the deployment into a project.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"name":"example-app"

}


version

The version property should not be used anymore.

Type: Number.

Valid values: 1, 2.

Specifies the Vercel Platform version the deployment should use.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"version":2

}


alias

The alias property should not be used anymore. To assign a custom Domain to your project, please define it in the Project Settings instead. Once your domains are, they will take precedence over the configuration property.

Type: Array or String.

Valid values: domain names (optionally including subdomains) added to the account, or a string for a suffixed URL using .vercel.app or a Custom Deployment Suffix ( available on the Enterprise plan).

Limit: A maximum of 64 aliases in the array.

The alias or aliases are applied automatically using Vercel for GitHub, Vercel for GitLab, or Vercel for Bitbucket when merging or pushing to the Production Branch.

You can deploy to the defined aliases using Vercel CLI by setting the production deployment environment target.

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"alias": ["my-domain.com","my-alias"]

}


scope

The scope property has been deprecated in favor of Project Linking, which allows you to link a Vercel project to your local codebase when you run vercel.

Type: String.

Valid values: For teams, either an ID or slug. For users, either a email address, username, or ID.

This property determines the scope ( Hobby team or team) under which the project will be deployed by Vercel CLI.

It also affects any other actions that the user takes within the directory that contains this configuration (e.g. listing environment variables using vercel secrets ls).

{

"$schema":"https://openapi.vercel.sh/vercel.json",

"scope":"my-team"

}

Deployments made through Git will ignore the scope property because the repository is already connected to project.

env

We recommend against using this property. To add custom environment variables to your project define them in the Project Settings.

Type: Object of String keys and values.

Valid values: environment keys and values.

Environment variables passed to the invoked Vercel functions.

This example will pass the MY_KEY static env to all Vercel functions and the SECRET resolved from the my-secret-name secret dynamically.

{

}

"env": {

"SECRET":"@my-secret-name"

"$schema":"https://openapi.vercel.sh/vercel.json",

"MY_KEY":"this is the value",

}

Environment variables passed to the Build processes.

Type:Object of String keys and values inside the buildObject.

Valid values: environment keys and values.

We recommend against using this property. To add custom environment variables to your project define them in the Project Settings.

{

}

"env": {

"MY_KEY":"this is the value",

"$schema":"https://openapi.vercel.sh/vercel.json",

The following example will pass the MY_KEY environment variable to all Builds and the SECRET resolved from the my-secret-name secret dynamically.

}

Type:Array of build Object.

"SECRET":"@my-secret-name"

Valid values: a list of build descriptions whose src references valid source files.

We recommend against using this property. To customize Vercel functions, please use the functions property instead. If you'd like to deploy a monorepo, see the Monorepo docs.

{

Build object definition

  • src (String): A glob expression or pathname. If more than one file is resolved, one build will be created per matched file. It can include * and **.
  • use (String): An npm module to be installed by the build process. It can include a semver compatible version (e.g.: @org/proj@1).
  • config (Object): Optionally, an object including arbitrary metadata to be passed to the Builder.

{ "src":"*.py","use":"@vercel/python" },

"$schema":"https://openapi.vercel.sh/vercel.json",

]

}

"builds": [

{ "src":"*.js","use":"@vercel/node" }

{ "src":"*.html","use":"@vercel/static" },

The following will include all HTML files as-is (to be served statically), and build all Python files and JS files into Vercel functions:

Previous

Last updated August 14, 2026


Project Configuration

Was this helpful?

Cross-link map: Static Configuration with vercel.json (/docs/project-configuration/vercel-json)From the Vercel docs graph (built 2026-09-21T05:26:59.511Z), spanning vercel.com docs + KB, nextjs.org, ai-sdk.dev, and other Vercel documentation sites. Full graph as JSON: https://vercel.com/docs/graph.jsonSemantically closest pagesProgrammatic Configuration with vercel.ts — Define your Vercel configuration in vercel.ts with @vercel/config for type-safe routing and build settings.Vercel Primitives — Learn about the Vercel platform primitives and how they work together to create a Vercel Deployment.Advanced Configuration — Learn how to add utility files to the /api directory, and bundle Vercel Functions.Runtimes — Runtimes transform your source code into Functions, which are served by our CDN. Learn about the official runtimes suppoBuild Output Configuration — Learn about the Build Output Configuration file, which is used to configure the behavior of a Deployment.PrerequisitesProject Configuration — Learn how to configure your Vercel projects using vercel.json, vercel.toml, vercel.ts, or the dashboard to control buildThis page links to (46)output — Next.js automatically traces which files are needed by each page to allow for easy deployment of your application. LearnAccount Management — Learn how to manage your Vercel account and team members.Build Features for Customizing Deployments — Learn how to customize your deployments using Vercel's build features.Configuring a Build — Vercel automatically configures the build settings for many front-end frameworks, but you can also customize the build aVercel CDN Cache — Learn how Vercel's CDN cache stores your content across a global network to reduce latency and origin load.Vercel CLI Overview — Learn how to use the Vercel command-line interface \(CLI\) to manage and configure your Vercel Projects from the commandvercel dev — Learn how to replicate the Vercel deployment environment locally and test your Vercel Project before deploying using theLinking Projects with Vercel CLI — Learn how to link existing Vercel Projects with Vercel CLI.Cron Jobs — Learn about cron jobs, how they work, and how to use them on Vercel.Environments — Environments are for developing locally, testing changes in a pre-production environment, and serving end-users in produAdding & Configuring a Custom Domain — Learn how to add a custom domain to your Vercel project, verify it, and correctly set the DNS or Nameserver values.Deploying & Redirecting Domains — Learn how to deploy your domains and set up domain redirects with this guide.Environment variables — Learn more about environment variables on Vercel.Reserved environment variables — Reserved environment variables are reserved by Vercel Vercel Function runtimes.Fluid compute — Learn about fluid compute, an execution model for Vercel Functions that provides a more flexible and efficient way to ruVercel Functions — Build API routes, webhooks, and agent request handlers with Vercel Functions, then test and debug them with Vercel CLI.Configuring Memory and CPU for Vercel Functions — Learn how to set the memory / CPU of a Vercel Function.Configuring regions for Vercel Functions — Learn how to configure regions for Vercel Functions.Functions API Reference — Learn about available APIs when working with Vercel Functions.Vercel Functions Limits — Learn about the limits and restrictions of using Vercel Functions.Runtimes — Runtimes transform your source code into Functions, which are served by our CDN. Learn about the official runtimes suppoUsing the Bun Runtime with Vercel Functions — Learn how to use the Bun runtime with Vercel Functions to create fast, efficient functions.Edge Runtime — Learn about the Edge runtime, an environment in which Vercel Functions can run.Using the Node.js Runtime with Vercel Functions — Learn how to use the Node.js runtime to create functions and deploy Node.js servers on Vercel.Deploying Git Repositories with Vercel — Vercel automatically deploys supported Git repositories on every branch push and when changes merge into the productionDeploying Bitbucket Projects with Vercel — ​Vercel for Bitbucket automatically deploys your Bitbucket projects with Vercel, providing Preview Deployment URLs, andDeploying GitHub Projects with Vercel — Vercel for GitHub automatically deploys your GitHub projects with Vercel, providing Preview Deployment URLs, and automatDeploying GitLab Projects with Vercel — ​Vercel for GitLab automatically deploys your GitLab projects with Vercel, providing Preview Deployment URLs, and automaSystem Headers — This reference covers the list of request, response, cache-control, and custom response headers included with deploymentImage Optimization with Vercel — Transform and optimize images to improve page load performance.Incremental Static Regeneration \(ISR\) — ISR serves cached static pages while regenerating content in the background. Vercel\\Using Monorepos — Vercel provides support for monorepos. Learn how to deploy a monorepo here.Secure Compute — Secure Compute provides dedicated private networks with VPC peering for Enterprise teams.Project settings — Use the project settings, to configure custom domains, environment variables, Git, integrations, deployment protection,Projects overview — A project is where you deploy and operate frontend apps, APIs, backends, containers, and agent workloads on Vercel.Global network and regions — View the list of regions supported by Vercel's CDN and learn about our global infrastructure.Routing Middleware — Learn how you can use Routing Middleware, code that executes before a request is processed on a site, to provide speed aRouting Middleware API — Learn how you can use Routing Middleware, code that executes before a request is processed on a site, to provide speed aRedirects — Learn how to use redirects on Vercel to instruct Vercel's platform to redirect incoming requests to a new URL.Bulk Redirects — Learn how to import thousands of simple redirects from CSV, JSON, or JSONL files.Rewrites on Vercel — Learn how to use rewrites to send users to different URLs without modifying the visible URL.Services — Deploy multiple backends and frontends within a single Vercel project using services.Services routing — Learn how Vercel routes public requests to services and how each service handles its own routes.WAF Custom Rules — Learn how to add and manage custom rules to configure the Vercel Web Application Firewall \(WAF\).Enhancing Security for Redirects and Rewrites — Learn how security measures in URI handling can prevent semantic attacks, where malicious hosts exploit redirects and reVercel Pricing — Choose a Vercel plan and compare features and usage pricing.Pages that link here (57)By site: vercel-changelog (1) · vercel-kb (12) · vercel-docs (44)From vercel-changelogServer-Timing response headers will pass through to the clientFrom vercel-kbAre Vercel Preview Deployments indexed by search engines? — Vercel Preview Deployments aren't indexed by default. Learn how the noindex header works, how to confirm it, and the cusBuild Claude Managed Agents with Vercel Services — Deploy Claude Managed Agents with Vercel Services to run a streaming research analyst in a browser chat, using AnthropicDeploy a Node.js Fastify app on Vercel with Docker — Build a Node.js application with Fastify and Docker, then deploy it to Vercel Functions. Learn how to configure environmDeploy Rust on Vercel with Docker — Build a Rust application with Axum and Docker, then deploy it to Vercel Functions. Learn how to configure environment vaDeploy ASP.NET Core on Vercel with Docker — Build a .NET application with Docker and deploy it to Vercel Functions. Learn how to configure environment variables, inConditional Build Commands: Environment, Branch, and Custom Workflows — Run a different Vercel build command for each environment or Git branch using a shell script, vercel.json, or vercel.ts,Full-stack previews on Vercel — Learn how to use full-stack previews for your Vercel projects. Deploy Next.js, FastAPI, and a containerized Go service tManage cache tags for external origins — Learn how to use cache tags to optimally serve fresh content on Vercel when content from your external origin changesTranslate Kubernetes manifests to vercel.json — Translate Kubernetes Deployments, Services, Ingress, ConfigMaps, and CronJobs into vercel.json configuration and VercelDeploy Laravel on Vercel with Docker — Build a Laravel application with FrankenPHP and Docker, then deploy it to Vercel with production configuration, externalDeploy Symfony on Vercel with Docker — Build a Symfony application with FrankenPHP and Docker, then deploy it to Vercel with production configuration, externalCan I use Vercel as a reverse proxy? — Learn how to use rewrites to proxy requests from Vercel to other deployments.From vercel-docsBuild Output Configuration — Learn about the Build Output Configuration file, which is used to configure the behavior of a Deployment.Features — Learn how to implement common Vercel platform features through the Build Output API.Build image overview — Learn about the container image used for Vercel builds.Configuring a Build — Vercel automatically configures the build settings for many front-end frameworks, but you can also customize the build aCache-Control headers — Learn about the cache-control headers sent to each Vercel deployment and how to use them to control the caching behaviorGetting started with cron jobs — Learn how to schedule cron jobs to run at specific times or intervals.Optimize Deployment Storage — Set retention periods, review remaining usage, and reduce deployment output size.Log Drains Reference — Learn about Log Drains - data formats, sources, environments, and security configuration.Fluid compute — Learn about fluid compute, an execution model for Vercel Functions that provides a more flexible and efficient way to ruVite on Vercel — Deploy Vite projects to Vercel and configure environment variables, Vercel Functions, server-side rendering, and SPA rewDeploy a Django app on Vercel — Deploy a Django app on Vercel. Learn how the Python runtime, WSGI, ASGI, static assets, and Vercel Functions work togethConfiguring Functions — Learn how to configure the runtime, region, maximum duration, and memory for Vercel Functions.Advanced Configuration — Learn how to add utility files to the /api directory, and bundle Vercel Functions.Configuring Maximum Duration for Vercel Functions — Learn how to set the maximum duration of a Vercel Function.Configuring regions for Vercel Functions — Learn how to configure regions for Vercel Functions.Functions API Reference — Learn about available APIs when working with Vercel Functions.Vercel Functions Limits — Learn about the limits and restrictions of using Vercel Functions.Runtimes — Runtimes transform your source code into Functions, which are served by our CDN. Learn about the official runtimes suppoUsing the Bun Runtime with Vercel Functions — Learn how to use the Bun runtime with Vercel Functions to create fast, efficient functions.Using the Go Runtime with Vercel Functions — Learn how to use the Go runtime to run Go APIs on Vercel.Python Functions in the /api Directory — Configure existing Vercel projects that use file-based Python functions in an /api directory.System Headers — This reference covers the list of request, response, cache-control, and custom response headers included with deploymentResponse headers — Learn about the response headers sent to each Vercel deployment and how to use them to process responses before sendingLimits — Look up account limits, usage summaries, rate limits, and resource constraints for every Vercel plan.Monorepos FAQ — Learn the answer to common questions about deploying monorepos on Vercel.Package Managers — Discover the package managers supported by Vercel for dependency management. Learn how Vercel detects and uses npm, YarnProject Configuration — Learn how to configure your Vercel projects using vercel.json, vercel.toml, vercel.ts, or the dashboard to control buildGit Configuration — Learn how to configure Git for your project through vercel.json or vercel.ts.Security settings — Configure security settings for your Vercel project, including Logs and Source Protection, Vercel Support Code VisibilitStatic Configuration with vercel.toml — Configure your Vercel project with a TOML file using the same properties as vercel.json.Programmatic Configuration with vercel.ts — Define your Vercel configuration in vercel.ts with @vercel/config for type-safe routing and build settings.Projects overview — A project is where you deploy and operate frontend apps, APIs, backends, containers, and agent workloads on Vercel.Transferring a project — Learn how to transfer a project between Vercel teams.Monitoring Reference — This reference covers the clauses, fields, and variables used to create a Monitoring query.Routing — Learn how Vercel's CDN routes requests through firewall, project routes, and deployment routes before reaching your applRouting Middleware — Learn how you can use Routing Middleware, code that executes before a request is processed on a site, to provide speed aRouting Middleware API — Learn how you can use Routing Middleware, code that executes before a request is processed on a site, to provide speed aGetting Started with Routing Middleware — Learn how you can use Routing Middleware, code that executes before a request is processed on a site, to provide speed aBulk Redirects — Learn how to import thousands of simple redirects from CSV, JSON, or JSONL files.Getting Started — Learn how to import thousands of simple redirects from CSV, JSON, or JSONL files.Rewrites on Vercel — Learn how to use rewrites to send users to different URLs without modifying the visible URL.Service configuration reference — Options available for service configuration.Services routing — Learn how Vercel routes public requests to services and how each service handles its own routes.WAF Custom Rules — Learn how to add and manage custom rules to configure the Vercel Web Application Firewall \(WAF\).