HotupdaterHot Updater
Self Hosting (Managed)

Vercel Provider

Deploy Hot Updater on Vercel with Blob, a Function, and Postgres, then connect your app.

Overview

Use this preset to provision an OTA server on Vercel: bundles in a Vercel Blob store, metadata in a PostgreSQL database, and the server in a Vercel Function. For a new app, start with Choose infrastructure. Provision the provider resources here, then connect your app with the verified URL and key.

Prerequisites

You need the following resources and access. An AI agent can prepare missing resources through its available provider tools.

  • Node.js: The CLI requires 20.19+. Agent setup uses a client-key helper that requires Node 22.18+ or Node 24+; prepare it before provisioning resources.
  • Vercel account: Sign up at Vercel if you don't have one. Init signs in with the Vercel CLI, or uses VERCEL_TOKEN when it is set.
  • PostgreSQL database: A database from the Vercel Marketplace, such as Neon, connected to the project, or any PostgreSQL connection URL. Init can create a Neon database for you; the Vercel CLI asks you to accept Neon's terms the first time.

Step 1: Install required packages

Complete Install packages in the React Native project before running init or an agent scaffold. Install the CLI, React Native SDK, and the build adapter that matches your app, then install this provider:

npm install @hot-updater/vercel --save-dev

An agent can perform these steps after inspecting the app's package manager and build configuration.

Step 2: Configure Vercel

Choose how to set up Vercel:

Install the Hot Updater skill, then ask your coding agent:

$hot-updater Set up infrastructure on Vercel for this project.

The agent inspects your app, discovers existing configuration and resources, and asks only for missing choices or access. It uses hot-updater agent infra setup to generate the deployment templates, then applies and verifies them with available provider tools. If authentication is needed, sign in through the provider or save credentials in a local ignored file; do not paste secrets into the conversation. See Agent Infrastructure for setup and resume.

After setup, review the local configuration. Interactive init writes the settings below to .env.hotupdater; an agent merges the needed settings into your project. Resource names and IDs are persisted for deterministic reruns. The Blob token, the database URL and VERCEL_TOKEN are persisted only when you consent.

HOT_UPDATER_VERCEL_TEAM_ID=your-team-id
HOT_UPDATER_VERCEL_PROJECT_NAME=your-project-name
HOT_UPDATER_VERCEL_PROJECT_ID=your-project-id
HOT_UPDATER_VERCEL_BLOB_STORE_NAME=your-blob-store-name
HOT_UPDATER_VERCEL_BLOB_STORE_ID=your-blob-store-id
HOT_UPDATER_API_KEY=your-api-key
# Included only when credential persistence is approved:
HOT_UPDATER_VERCEL_BLOB_READ_WRITE_TOKEN=your-blob-read-write-token
HOT_UPDATER_VERCEL_DATABASE_URL=your-postgres-url

Init connects the Blob store to the project's production environment, which adds HOT_UPDATER_VERCEL_BLOB_READ_WRITE_TOKEN to the project, and sets HOT_UPDATER_VERCEL_DATABASE_URL there. The Function reads these production environment variables.

The Blob store is always private: devices download bundles only through signed URLs that expire, which the server issues to requests with a valid API key. Init does not use a public store.

Managed init reuses HOT_UPDATER_API_KEY when supplied or creates an API key, registers it in the database, and persists the plaintext value locally. Send this API key in the app's x-api-key request header. To list, add, or revoke keys later, run hot-updater api-key from the app directory.

Provider credentials from .env.hotupdater are not included in your app bundle unless you explicitly configure that behavior. The API key is the exception: add HOT_UPDATER_API_KEY to your React Native build-time configuration as shown in Set up your app, but never add the Blob token, the database URL or a Vercel token.

See Security.

Optional: Bundle signing

Managed Vercel init does not create or enable a signing key. After provisioning the OTA infrastructure, configure local PEM, AWS KMS, or Google Cloud KMS signing, embed its public key in a native release, and only then deploy signed bundles. Storage and database selection does not constrain the signer.

Step 3: Add HotUpdater to your project

After provisioning, record these outputs for Set up your app:

OutputValue
Client base URLThe project's production domain, such as https://<your-project>.vercel.app
Client request headerx-api-key
Client API keyThe saved HOT_UPDATER_API_KEY in your ignored .env.hotupdater
Deploy configurationhot-updater.config.ts and the selected provider resources

Use the URL init prints. Configure the SDK and native bundle loader through Set up your app, using the selected build adapter and the same update strategy as hot-updater.config.ts. Only the client API key belongs in the mobile app's build-time configuration; provider credentials stay in the deploy environment.

The managed Vercel Function exposes /version publicly. OTA update checks, Insights ingestion, and Remote Config fetches require x-api-key: $HOT_UPDATER_API_KEY. Internally, the Function runs the insights(), apiKeys(), and remoteConfig() plugins and mounts only handlers.client. Admin routes, including Insights queries and Remote Config publishing, are not mounted on the production URL.

Generated configuration and operations

Init generates hot-updater.config.ts with your Vercel Blob storage and PostgreSQL database, and plugins: the server plugins the managed Function runs, apiKeys(), insights(), and remoteConfig(), imported from hot-updater/plugins. The CLI and the Console reach the Blob store and the database through these settings and run the same plugins as the Function. The managed Function runs these official plugins only; to run other server plugins, use a custom server.

On a rerun, init updates storage, database, and plugins in the existing file and keeps your other settings, including a wrapped build such as withSentry(bare()). When it cannot edit hot-updater.config.ts, such as a config that a function returns, it leaves the file unchanged and prints the storage, database, and plugins lines to add.

hot-updater.config.ts
import { bare } from "@hot-updater/bare";
import { postgres, vercelBlobStorage } from "@hot-updater/vercel";
import { apiKeys, insights, remoteConfig } from "hot-updater/plugins";
import { defineConfig } from "hot-updater";
import { existsSync } from "node:fs";

if (existsSync(".env.hotupdater")) {
  process.loadEnvFile(".env.hotupdater");
}

export default defineConfig({
  build: bare({ enableHermes: true }),
  storage: vercelBlobStorage({
    token: process.env.HOT_UPDATER_VERCEL_BLOB_READ_WRITE_TOKEN!,
  }),
  database: postgres({
    connectionString: process.env.HOT_UPDATER_VERCEL_DATABASE_URL!,
  }),
  plugins: [apiKeys(), insights(), remoteConfig()],
  updateStrategy: "appVersion", // or "fingerprint"
});

Step 4: If you use Expo, add the config plugin

Follow the Expo path in Set up your app. It applies the config plugin and generates the native integration. For DOM components, continue with Expo DOM components.

Step 5: Add native code

For Bare or Rock, follow the Android and iOS instructions in Set up your app. Keep the integration appropriate to your React Native version and rebuild the native app after changing it.

Upgrade infrastructure

Rerun hot-updater init with the saved inputs: it migrates the database and redeploys the Function from the installed @hot-updater/vercel. With the Hot Updater skill attached, you can also ask your agent:

$hot-updater Upgrade this project's existing Vercel server infrastructure.

The agent discovers the existing deployment, uses hot-updater agent infra upgrade, and reads the applicable version files before changing resources. It applies pending changes and verifies the server with doctor. See Upgrade an existing server for the workflow or Doctor for terminal instructions.

For server templates to apply with your own deployment tooling, use hot-updater infra scaffold --provider vercel. See Infrastructure Templates.

Verifying the setup

  1. Confirm the selected Vercel resources and the deployed client base URL.

  2. From the React Native project, check the server and native integration:

    npx hot-updater doctor --server-base-url <client-base-url> --json

    Doctor checks the public /version endpoint. It does not prove an authenticated update download or application.

  3. Complete Test an OTA update on a release build. Verify that the app downloads and runs the changed code, then survives a restart.

An agent should report the selected resources, verified URL, configuration file paths and verification result. Report a missing access, billing or native-build prerequisite explicitly instead of marking an untested installation complete.

Host the Console

The console can run on Vercel, Cloudflare Workers, Netlify, or Docker/Node with the same Blob store and database settings. See the console hosting matrix.

On this page