Can I export my Lovable project?
Last checked 31 Aug 2026
Short answer
Yes. Sync the project to your own GitHub or GitLab repository, or download the codebase from the code editor. It is a standard project you can run anywhere.
Two routes out
- Git sync — connect GitHub (including Enterprise) or GitLab and the project stays two-way synced with a repository you own. Best long-term option.
- Download — take the codebase from the built-in code editor as a one-off snapshot.
What travels with you
- All application source: components, routes, styles, configuration
- Server functions and integration code
- Database migrations, where they are stored in the project
What does not automatically travel
- The managed Cloud backend itself — data and configuration must be migrated to a backend you control
- Environment secrets, which you re-add wherever you host
- Lovable's hosting and publishing pipeline
Practical advice
Turn on Git sync early, even if you never intend to leave. It gives you an independent backup, a change history in a format any developer understands, and an instant answer to "what happens if we outgrow this?".
Two ways to get the code out
- Connect GitHub. The cleanest route: your project becomes a repository you own, kept in sync as you build. Clone it and work locally with any editor.
- Download the repository. Once GitHub is connected you can download an archive from the repository like any other project.
What comes with the export
A standard front-end project: source files, components, routes, styles, configuration and dependency manifest. It builds and runs locally with the usual install-and-run commands.
What does not travel automatically
- Your backend data. Tables, rows, users and storage live in the database, not the repository. Export them separately.
- Secrets. Environment values are held in the platform, not committed to code. Recreate them wherever you host.
- Hosting and the domain. Self-hosting means setting up your own build and deployment, DNS and SSL.
A safe self-host checklist
- Clone and run locally; confirm the app builds
- Recreate every environment variable
- Point the app at your backend, whether the managed one or your own
- Deploy to your host and confirm the build passes there
- Move DNS after the new deployment is verified, not before
- Retest auth, forms, payments and email on the new host
Do you own it?
Yes. The code Lovable generates for your project is yours — export it, modify it, host it elsewhere, or hand it to a developer. Keeping GitHub connected from the start means that option is always one clone away.
Sources
Was this answer helpful?
Related questions
- AnswerHow do I connect Lovable to GitHub?Open your project's Settings, go to the GitHub/Git sync integration, authorise Lovable's GitHub app, and choose or create the repository to sync with — Lovable then keeps code in sync both ways automatically.
- AnswerWhat's the difference between Lovable Cloud and Supabase?Lovable Cloud is a Supabase backend that Lovable runs and manages for you. Connecting your own Supabase project means you own the account, the dashboard and the bill.
- AnswerWhat is Lovable?Lovable is an AI app builder: you describe the website or app you want in plain English and it writes and runs the real code for you, in the browser.
- AnswerCan I move a Lovable website somewhere else?Yes. Export the code to your own repository, deploy it on any host that runs the stack, and migrate the backend and secrets. Plan for a few hours, not a few minutes.
You might also need
- GuideHow to Build Your First Website with LovableGo from a blank project to a published multi-page website, with the exact prompt structure that avoids the most common first-build mistakes.
- GuideWhat Is Lovable? A Plain-English ExplanationAn honest explanation of what Lovable actually does, what it generates, and where its limits are — written for people who are not developers.