Skip to Content

Frameworks

Backends


Nitro on Vercel

You can deploy a Nitro app to Vercel with zero configuration.

Nitro

To get started with Nitro on Vercel, use the following Nitro template to deploy to Vercel with zero configuration:

Copy page

Nitro is a full-stack framework with TypeScript-first support. It includes filesystem routing, code-splitting for fast startup, built-in caching, and multi-driver storage. It enables deployments from the same codebase to any platform with output sizes under 1MB.

vc initnitro

Get started with Vercel CLI

When you deploy a Nitro app to Vercel, you can use Vercel specific features such as Incremental Static Regeneration (ISR), preview deployments, Fluid compute, Observability, and Vercel firewall with zero or minimum configuration.

Get started by initializing a new Nitro project using Vercel CLI init command:

Vercel deployments can integrate with your git provider to generate preview URLs for each pull request you make to your Nitro project.

On-demand revalidation

With on-demand revalidation, you can purge the cache for an ISR route whenever you want, foregoing the time interval required with background revalidation.

Using Vercel's features with Nitro

To revalidate a path to a prerendered function:

This will clone the Nitro example repository in a directory called nitro.

ISR allows you to create or update content without redeploying your site. ISR has three main benefits for developers: better performance, improved security, and faster build times.

  1. Create an Environment VariableCreate an Environment Variable to store a revalidation secret by:Using the command:

    openssl rand-base6432

    Or generating a secret to create a random value.
  2. Update your configurationUpdate your configuration to use the revalidation secret as follows:

    NitroNuxt

    TypeScript

    exportdefaultdefineNitroConfig({

    vercel: { config: {

    bypassToken:process.env.VERCEL_BYPASS_TOKEN,

    }, }, });
  3. Trigger revalidationYou can revalidate a path to a prerendered function by making a GET or HEAD request to that path with a header of x-prerender-revalidate: bypassTokenWhen the prerendered function endpoint is accessed with this header set, the cache will be revalidated. The next request to that function will return a fresh response.

routeRules: {


passQuery:true,

isr: {

'/products/**': {

To have more control over ISR caching, you can pass an options object to the isr route rule as shown below:

TypeScript

exportdefaultdefineNitroConfig({

},

},

allowQuery: ['q'],

},

The following options are available:

Option

Type


expiration

group

number | false

number

The expiration time, in seconds, before the cached asset is re-generated by invoking the serverless function. Setting the value to false (or isr: true in the route rule) will cause it to never expire.

Group number of the asset. Use this to revalidate multiple assets at the same time.

allowQuery

passQuery

string[] | undefined

boolean

List of query string parameter names that will be cached independently. If you specify an empty array, query values are not considered for caching. If undefined, each unique query value is cached independently. For wildcard /** route rules, url is always added.

When true, the query string will be present on the request argument passed to the invoked function. The allowQuery filter still applies.

Observability

With Vercel Observability, you can view detailed performance insights broken down by route and monitor function execution performance. This can help you identify bottlenecks and optimization opportunities.

Nitro (>=2.12) generates routing hints for functions observability insights, providing a detailed view of performance broken down by route.

To enable this feature, ensure you are using a compatibility date of 2025-07-15 or later.

Nitro Nuxt

TypeScript

exportdefaultdefineNitroConfig({

compatibilityDate:'2025-07-15',// or "latest"

});


ssrRoutes configuration to declare SSR routes. For more information, see #3475.

More resources

Last updated August 10, 2026

Cross-link map: Nitro on Vercel (/docs/frameworks/backend/nitro)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 pagesHow to ship a Nitro app on Vercel — Deploy a Nitro app to Vercel with zero configuration. Learn how to ship from a template, the Vercel CLI, or Git, and conBuild with a Nitro starter template — Deploy a Nitro app to Vercel from a starter template. Compare the Nitro Starter, route rules, cached HTTP handler, plugiWhat is the Nitro Vite plugin? — The Nitro Vite plugin \(nitro/vite\) adds SSR, API routes, and deploy-anywhere server builds to any Vite app. Learn whatMigrate a TanStack Start app from Netlify to Vercel — Move your TanStack Start app off Netlify and onto Vercel Functions, where Fluid compute scales it automatically. Swap toHow to Deploy a TanStack Start app to Vercel — Deploy a TanStack Start app to Vercel with the Nitro Vite plugin. Covers Git and CLI deployment, Fluid compute defaults,This page links to (13)vercel init — Learn how to initialize Vercel supported framework examples locally using the vercel init CLI command.Environments — Environments are for developing locally, testing changes in a pre-production environment, and serving end-users in produEnvironment variables — Learn more about environment variables on Vercel.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.Deploying Git Repositories with Vercel — Vercel automatically deploys supported Git repositories on every branch push and when changes merge into the productionIncremental Static Regeneration \(ISR\) — ISR serves cached static pages while regenerating content in the background. Vercel\\Getting started with ISR — Learn how to set up Incremental Static Regeneration \(ISR\) with time-based and on-demand revalidation.Observability — Find production errors, capture request traces, and discover queryable metrics with Vercel Observability and Vercel CLI.Observability Insights — List of available data sources that you can view and monitor with Observability on Vercel.Vercel Firewall — Learn how Vercel Firewall helps protect your applications and websites from malicious attacks and unauthorized access.Build with a Nitro starter template — Deploy a Nitro app to Vercel from a starter template. Compare the Nitro Starter, route rules, cached HTTP handler, plugiHow to ship a Nitro app on Vercel — Deploy a Nitro app to Vercel with zero configuration. Learn how to ship from a template, the Vercel CLI, or Git, and conPages that link here (3)By site: vercel-kb (3)Build with a Nitro starter template — Deploy a Nitro app to Vercel from a starter template. Compare the Nitro Starter, route rules, cached HTTP handler, plugiHow to ship a Nitro app on Vercel — Deploy a Nitro app to Vercel with zero configuration. Learn how to ship from a template, the Vercel CLI, or Git, and conBuild a Weather API on Vercel: Express, FastAPI, and Nitro — Build a weather API on Vercel with FastAPI, Express, or Nitro. Compare the three runtimes, add caching and Observability

Learn more about deploying Nitro projects on Vercel with the following resources:

Express

When you deploy a Nitro app to Vercel, your server routes automatically become Vercel Functions and use Fluid compute by default.

Backends

Was this helpful?