# Remix hosting in 2026: how to deploy a Remix app with its server

> A Remix app is a client folder and a server handler, so it cannot be published as plain files. Livops recognises Remix from package.json, runs the build, and starts remix-serve on the port it assigns.

Source: https://livops.dev/en/hosting/remix-hosting

By Livops team, the people who build and run Livops. Updated 28 November 2026.

Remix builds the browser assets into `build/client` and a request handler into `build/server`. A shared static server can serve the first folder but cannot run the second. So a Remix app needs a process that stays up, started after the build. Livops reads your `package.json`, recognises Remix from `@remix-run/react` or `@remix-run/dev`, and sets the commands for you. You can change them in the cabinet or in a `livops.json` file.

## The commands

Use these:

- build: `npm run build`
- start: `npx remix-serve ./build/server/index.js`

Put `@remix-run/serve` (or the `remix-serve` package your project already uses) in your dependencies. Then `npx` runs that version and not whichever one it finds first.

## React Router 7

A React Router 7 app in framework mode has the same two folders, because it is the same project shape under a new name. Its start command is `npx react-router-serve ./build/server/index.js`. The rest of this guide applies to it as well.

## The port

Livops sets the `PORT` environment variable. `remix-serve` listens on it. Do not hard-code a port in your code, and do not change the start command to use a fixed one. A fixed port makes the app unreachable on Livops.

Set the health check path to `/`, or to a page that always answers. If the check fails, the app is restarted, so a slow or broken home page will look like a crash loop in the logs.

## Environment variables

Put secrets and settings in the Variables section of the cabinet. Variables that start with `PUBLIC_` are written into the browser bundle when it is built, so a change to one needs a new deploy. Other variables are read by the server at runtime, and a restart is enough.

## Common mistakes

- **Running `remix dev` or `vite dev` in production.** The dev server is for your laptop. The build and the start command are what Livops runs.
- **Setting the output to `build/client` and nothing else.** The page loads, but every request that renders on the server fails, because `build/server` is missing from what the app needs.
- **A hard-coded port.** Use `PORT` from the environment.
- **No `remix-serve` in the project.** The start command then depends on what `npx` fetches, and that can change from one deploy to the next.

If your app uses another framework, the same rule holds: a server app is paid by memory. For the other frameworks that share this shape see [SvelteKit hosting](https://livops.dev/en/hosting/sveltekit-hosting) and [Nuxt hosting](https://livops.dev/en/hosting/nuxt-hosting).

## Questions

**Can a Remix app run as a free static site on Livops?**

No. A Remix build writes two folders. build/client holds the files a browser loads, and build/server holds the handler that renders each request. The handler needs a running process, so the app is a web app and is paid by the memory it uses.

**Why does Livops start remix-serve with npx?**

It runs the remix-serve that your project depends on, if there is one. Add it to your dependencies so the version that runs is the one you tested. Without it npx fetches whichever version it finds.

**Which folder is the output for Remix?**

The static assets are in build/client. The server entry that the start command runs is build/server/index.js. Do not set the output to build/client alone for a server app, because the server would be missing.

## Sources

1. [Remix — Documentation](https://remix.run/docs). Checked 28 November 2026.
2. [Remix — @remix-run/serve](https://v2.remix.run/docs/other-api/serve). Checked 29 November 2026.
