Can you self-host a Replit app?
Short answer: the Replit workspace and Replit Agent run only at Replit. The app you built with them is code you can push to GitHub and run on your own server. The work is in the parts Replit runs for the app: the database, the logins and the files.
What you can and cannot self-host
| Self-host? | What it means | |
|---|---|---|
| The Replit workspace and Agent | No | Replit runs them as a service |
| Your app's code | Yes | Push it to GitHub from the Git pane |
| The database | Yes | It is PostgreSQL. Copy it with pg_dump |
| Replit Auth | No | Replace it, for example with Supabase Auth |
| App Storage | No | Copy the files to other storage |
| Secrets | Yes | Copy each value by hand |
| The replit.app address | No | Point your own domain at the server |
What your server needs
- Node.js. PanelAlpha Engine installs what it needs on a new VPS and builds the app from GitHub.
- A PostgreSQL database. A Supabase project gives you one, with logins and file storage in the same place.
- The keys from Replit Secrets, as environment variables on the server.
- The port. Replit apps often listen on port 5000. On your server the app should read the port from the PORT variable.
Replit hosting or your own server
Replit bills the published app and its database by use: compute time and storage. A VPS has a fixed price. One that runs PanelAlpha Engine costs about $5 to $15 a month. The app, the engine and the updates are then on a server you control.
How the move works
Between 11 and 18 migration steps, depending on your app. The step-by-step guide shows only the ones you need.
- Push the project to GitHub and copy the secrets into a .env file.
- Back up the production database and restore it into a Supabase project you own.
- Let your AI tool switch the login to Supabase Auth and the uploads to Supabase Storage.
- Let it remove what only works on Replit, like the .replit file and the @replit packages.
- Deploy the app on your VPS through PanelAlpha Engine and point your domain at it.
Can you keep using Replit Agent?
The repository stays on GitHub, so you can still open it in Replit. But the app then depends on Supabase and your server, not on Replit services. The step-by-step guide moves the editing to Claude Code or Codex, which work on the same repository.
Sources
- Replit docs: Manually copy a project to another workspace
- Replit docs: Storage and databases
- Replit docs: Auth
- Replit docs: Publishing and database billing