Back to Blog
Tutorial9 min read2026-07-02

How to Deploy a SolidStart App to the Cloud

Deploy a SolidStart app to the cloud: understand Vinxi/Nitro presets, choose server vs static rendering, handle server functions, and deploy with a single Git push.

Ajay Kumar
Ajay Kumar
Founder & DevOps, PandaStack

SolidStart is the meta-framework for SolidJS, built on Vinxi and Nitro. Like other Nitro-based frameworks it can target many environments, but the cleanest production path is either a Node server (for SSR and server functions) or a static export (for content sites). Here's how to ship either one.

How SolidStart builds

SolidStart uses Vinxi to bundle and Nitro to produce the deployment output. A standard build:

npm run build

By default this produces a Node server under .output/. The preset is configurable in app.config.ts:

import { defineConfig } from '@solidjs/start/config'

export default defineConfig({
  server: {
    preset: 'node-server'
  }
})

For a fully static site, use the static preset and ensure your routes are prerenderable:

export default defineConfig({
  server: {
    preset: 'static'
  }
})

Server functions

SolidStart's "use server" functions and API routes execute on the server. This is the reason most apps deploy as a Node server rather than static — if you call a database or hold secrets in a server function, you need a running server process, not a pile of static files.

// a server function
async function getUser(id: string) {
  'use server'
  return db.user.findUnique({ where: { id } })
}

If your app uses any "use server" code or /api routes, deploy the Node-server output.

Running and configuring the server

The Node output starts with:

node .output/server/index.mjs

It honors PORT and binds 0.0.0.0 in the Node preset. Pass configuration through environment variables; in SolidStart, variables prefixed with VITE_ are exposed to the client at build time, so keep secrets unprefixed and read them only inside server code.

A Dockerfile

FROM node:20-slim AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build

FROM node:20-slim
WORKDIR /app
ENV NODE_ENV=production
COPY --from=build /app/.output ./.output
EXPOSE 3000
CMD ["node", ".output/server/index.mjs"]

The .output directory is self-contained, so the runtime stage needs nothing else.

Deploying on PandaStack

For SSR / server functions: deploy as a container app. PandaStack auto-detects Node, runs the build, and serves the Node output via Helm on GKE with automatic SSL and live logs. Set environment variables in the [dashboard](https://dashboard.pandastack.io); attach a managed PostgreSQL database and read DATABASE_URL inside your server functions.

For static export: deploy as a static site. PandaStack builds in pandastack.ai microVMs and serves the output behind a CDN with free SSL. The free tier covers 5 static sites.

Use casePresetPandaStack app type
Marketing/content sitestaticStatic site
App with server functionsnode-serverContainer app
App needing a databasenode-serverContainer app + managed DB

Watch the cold start

SolidStart's server output is lightweight, so it boots quickly. On a free-tier container app with KEDA scale-to-zero, the first request after idle still incurs a cold start; for production traffic use a paid tier that keeps an instance warm.

References

  • [SolidStart documentation](https://docs.solidjs.com/solid-start)
  • [SolidStart deployment guide](https://docs.solidjs.com/solid-start/building-your-application/deployment)
  • [Vinxi documentation](https://vinxi.vercel.app/)
  • [Nitro deployment presets](https://nitro.build/deploy)

SolidStart deploys cleanly whether static or server-rendered. Try PandaStack's free tier with a managed database at [dashboard.pandastack.io](https://dashboard.pandastack.io).

Ready to deploy?

Start free on PandaStack.

Start free on PandaStack

More in Tutorial

Browse all Tutorial articles →

See also