Menu
Urgent
Patch your vulnerable projects

Elysia on Vercel

Last updated November 14, 2025

Elysia is an ergonomic web framework for building backend servers with Bun. Designed with simplicity and type-safety in mind, Elysia offers a familiar API with extensive support for TypeScript and is optimized for Bun.

You can deploy an Elysia app to Vercel with zero configuration.

Elysia applications on Vercel benefit from:

  • Fluid compute: Active CPU billing, automatic cold start prevention, optimized concurrency, background processing, and more
  • Preview deployments: Test your changes on a copy of your production infrastructure
  • Instant Rollback: Recover from unintended changes or bugs in milliseconds
  • Vercel Firewall: Protect your applications from a wide range of threats with a multi-layered security system
  • Secure Compute: Create private links between your Vercel-hosted backend and other clouds

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

Minimum CLI version required: 49.0.0

This will clone the Elysia example repository in a directory called .

To deploy, connect your Git repository or use Vercel CLI:

Minimum CLI version required: 49.0.0

To run an Elysia application on Vercel, create a file that imports the package at any one of the following locations:

The file must also export the application as a default export of the module or use a port listener.

For example, use the following code that exports your Elysia app:

Running your application using is currently not supported. For now, prefer .

To run your Elysia application locally, you can use Vercel CLI:

Minimum CLI version required: 49.0.0

Ensure is set to in your file:

Minimum CLI version required: 49.0.0

To use the Bun runtime on Vercel, configure the runtime in :

For more information, visit the Bun runtime on Vercel documentation.

In Elysia, you can use plugins and lifecycle hooks to run code before and after request handling. This is commonly used for logging, auth, or request processing:

In Vercel, Routing Middleware executes before a request is processed by your application. Use it for rewrites, redirects, headers, or personalization, and combine it with Elysia's own lifecycle hooks as needed.

When you deploy an Elysia app to Vercel, your server endpoints automatically run as Vercel Functions and use Fluid compute by default.


Was this helpful?

supported.