Skip to main content
Hostwares

How do you move a Replit app to your own server?

Push the Repl to GitHub, then run it on a machine you control: a full-root Cloud Instance if the app needs background workers, cron or several processes, or a pack if it is one web process. Three things never leave Replit on their own and must be redone: Secrets, the Replit database or key-value store, and files written to the Repl's disk. On Hostwares an instance comes with root over a web terminal, an app deployed from the same repository if you want it, a hostname with HTTPS, and your own domain.

Step by step

  1. 1

    Push the Repl to GitHub

    Use the Git pane in the Replit workspace to connect a GitHub repository and push, or download the project as a ZIP and push it from your computer. Check that the run command from .replit (or package.json) is recorded, because the new host needs it.

    From a ZIP

    unzip repl.zip && cd <project>
    git init && git add . && git commit -m "from replit" && git push -u origin main
  2. 2

    Choose the shape of the host

    One web process (Express, Flask, FastAPI, Next.js): Dashboard → Deployments → New with the repository and a pack; the framework is detected. Several processes, a bot that must run all day, cron jobs, or anything that writes to local disk: Dashboard → Instances → New for a full-root instance and deploy the repository onto it, or install things by hand from the web terminal.

  3. 3

    Re-enter the Secrets

    Replit Secrets are stored outside the project files and are not in the export. Add each on the Environment tab (set_env over MCP), or as an .env on the instance. list_env_vars shows the names you have set without the values.

  4. 4

    Move the database

    A Replit PostgreSQL database: pg_dump it from the Repl shell and restore it into a managed Postgres from Hostwares (create_database over MCP gives you one; db_connection_info returns the connection string). The Replit key-value store has no equivalent: export it to JSON from a short script and load it into a table.

    In the Repl shell

    pg_dump "$DATABASE_URL" --no-owner -Fc > app.dump
    # then, from your computer
    pg_restore --no-owner -d "<new DATABASE_URL>" app.dump
  5. 5

    Point the domain and verify

    Domains tab on the site, or the instance's domain panel, then create the record it shows at your registrar. The certificate is issued once DNS resolves. Hit an API route, let the app run for a day, and read the logs (get_logs) for anything it wrote to a path that no longer exists.

What breaks, and the fix

process.env.X is undefined
Replit Secrets are not exported. Add them on the Environment tab or in .env on the instance.
The app reads or writes files that are gone
Replit's workspace paths do not exist on the new host. Point the code at a path on the instance's disk or at object storage.
The run command is unknown
Copy it from .replit or package.json into the site's start command, or into a systemd unit on the instance.
Always-on or scheduled work stops
On an instance, run it as a service or a cron entry; a pack runs one web process.

What it costs

  • One web process: a Frontend pack from $1/mo.
  • A full-root Cloud Instance from $2/mo; a managed Postgres from $10/mo.
  • Flat for the term; no compute units, no request meter.

App

$1/mo

Starter Frontend pack, 1 vCPU / 1 GB RAM / 10 GB

Database, users and files

$5/mo

Smallest dedicated Supabase pack; several projects fit on one

For comparison

  • Replit Core (monthly; $18/mo billed annually; deployments draw from plan credits): $20/mo (checked 2026-11-06, replit.com)
  • Replit Autoscale deployment base fee, plus compute units and requests: $2/mo base (checked 2026-11-06, replit.com)

Questions

Do I need a Cloud Instance or is a pack enough?+

A pack is enough for one web process that listens on a port. Pick an instance for several processes, Discord or Telegram bots, cron jobs, or anything that writes to local disk.

Can I get my Replit database out?+

Yes. Replit's PostgreSQL is standard Postgres: pg_dump in the Repl shell, pg_restore into a managed database from Hostwares. The key-value store needs a short export script.

Does Replit export my Secrets?+

No. Secrets live outside the project files. Write them down from the Secrets pane and add them on the new host.

What do I get root for?+

A Cloud Instance gives you a full-root web terminal: install system packages, run several services, keep a bot alive, schedule jobs. Agents can run commands on it through site_terminal, one command per call with approval.

Can an AI do the move?+

Mostly. Add Hostwares to Claude Code or Cursor and ask it to deploy the repository and set the environment; it uses deploy, set_env, create_database and add_domain. Pulling Secrets out of Replit is the one part you do by hand.

What does it cost?+

A Frontend pack from $1/mo for one process, or a Cloud Instance from $2/mo plus a managed Postgres from $10/mo for a full stack. Flat for the term.