# Moving a Replit app off Replit

> Replit’s version control is Git, so push the code to GitHub, then copy the production Postgres database using its connection string. Plan sign-in before you move, since Replit Auth uses Replit accounts, and replace secrets, connectors and App Storage calls.

Canonical: https://shipfast.online/rescue/replit/leave/
Last updated: 2026-10-25

By [Prayag Dalal](https://shipfast.online/about/). Checked against Replit's documentation on 2026-10-25.

## Symptoms

- Hosting costs are growing with traffic, or you need a specific cloud.
- A developer wants to work in their own environment and pipeline.
- You want a copy of the code and data outside Replit.

## Why it happens

Version control on Replit is Git: Agent checkpoints, the Git pane and the Git command line all use the same repository, and it syncs with GitHub. So the code moves cleanly.

The production database is PostgreSQL, and any Postgres-compatible client can connect to it with the connection string from its Settings tab, which is how you copy the data out. Secrets, sign-in and files in App Storage each need their own plan.

## What Replit already handles

- **Git and GitHub:** Push the repository to GitHub from the Git pane.
- **Production database access:** The connection string in the production database’s Settings tab works with any PostgreSQL client.
- **App Storage access:** Files are reachable with Replit’s SDKs and Google Cloud Storage client libraries.

## Fix it yourself

1. **Push the code to GitHub.** Tools → Git, initialise the repository if needed, connect GitHub and push.
2. **List secrets and integrations.** Every secret, sign-in setting, Stripe webhook and email setting the app uses.
3. **Copy the production data.** Use the production connection string with a Postgres tool such as pg_dump to copy it into the new database.
4. **Plan sign-in.** Replit Auth signs users in with Replit accounts, so choose how they’ll sign in on the new host before switching. Clerk Auth gives your app its own user accounts.
5. **Rehearse, then switch.** Run the app on the new host against a copy of the data, move DNS, and keep the Replit app until you’re sure.

## Where it still goes wrong

- Data written after your copy needs a final sync or a short pause in writes.
- Replit-specific pieces, such as connectors and App Storage calls, need replacing in the code.
- Once you’re off, regenerate the production database credentials so the old connection string can’t be used.

## FAQ

### Can I export my Replit app’s code?

Yes. Replit’s version control is Git, and the Git pane syncs with GitHub.

### Can I get my production database out of Replit?

Yes. Connect any PostgreSQL-compatible client using the connection string in the production database’s Settings tab.

### Will my users need new accounts?

With Replit Auth they sign in with Replit accounts, so plan the new sign-in method before you move. Clerk Auth gives your app its own accounts.

## Sources

- [Replit docs: Version control](https://docs.replit.com/learn/projects-and-artifacts/version-control)
- [Replit docs: Database connection details](https://docs.replit.com/features/data-and-storage/connection-details)
- [Replit docs: Auth](https://docs.replit.com/learn/projects-and-artifacts/auth)
- [Replit docs: Storage and databases](https://docs.replit.com/learn/projects-and-artifacts/storage-and-databases)

## Get it fixed

App rescue, From $1,000, fixed price: [send your app](https://shipfast.online/contact/?service=app-rescue).

## Related

- [All Replit guides](https://shipfast.online/rescue/)
- [Free production readiness check](https://shipfast.online/tools/production-readiness-check/)
