The preview and the live site are different builds with different settings. Almost always it is one of four things: you did not republish, a refreshed page returns 404, the sign-in redirect is not allowed on the live domain, or a key that existed in the editor is missing on the host.
The preview is the editor's own view of your project. The live site is a copy made at one moment and served from somewhere else. Lovable's docs say it plainly: the published site is a snapshot, and edits after publishing do not reach visitors until you publish again. Replit deployments work the same way, running a saved snapshot so editor changes do not affect the live build. So ask first: did you publish after the last change?
If you did, the next four causes cover most cases:
- A refresh returns 404. Lovable's older React apps build to static files. The host must return
index.htmlwith a 200 status for any route that is not a file. Without that rule, the home page works and every deep link or refresh fails. Netlify and Cloudflare use a_redirectsfile, Vercel usesvercel.json. - Sign-in fails only on the live domain. Your auth provider keeps a list of allowed redirect URLs. The preview URL is on it. Your custom domain is not. Add it in Supabase, and in Google or GitHub if you use them.
- A key or setting is missing on the host. Lovable embeds
VITE_SUPABASE_URLand the publishable key at build time, so changing them needs a rebuild. On Replit, secrets for the published app are set separately under Publishing. On v0 and Next.js, onlyNEXT_PUBLIC_variables reach the browser, and server secrets must be set on Vercel. - The live database is not the preview database. On Replit, publishing creates a separate production database. Rows you added while building are not there unless you copied them. Testing and real users should use different databases, so this is correct, but it looks like data loss.
Two more that catch apps with payments. Stripe test keys work in preview and live keys are set on the host, or the other way round. And the Stripe webhook still points at the preview URL, so payments succeed and the app never hears about them.
What to check, in order:
- Publish again and hard-refresh the live site.
- Open a deep link on the live site and press refresh. If you get 404, add the fallback rule.
- Sign in on the live domain and read the error. A redirect error means the URL list.
- Open the browser's developer tools on the live site, then the Console and Network tabs. A failed request names the missing key or the wrong URL.
- For Lovable custom domains, open Project, Settings, Domains and confirm the status reads Live.
Money and time. Most of these are a single fix at €99–$990, about two days. A check that goes through all of them is $49–$800. See pricing.
Get help when the console shows errors you cannot read, when the live site reaches a database you do not recognize, or when payments go through and nothing unlocks. The Claude Code guide covers the localhost version of this problem, and v0 and Bolt have their own pages.
Check these
Secrets live in the host's environment settings
Keys belong in environment variables on the server, not in the repository or in front-end code.
Sign-up confirmation and password reset work end to end
Use a real inbox. Check that the link arrives, points to your live domain, and works once.
Testing and real users use separate databases
Experiments and AI agents should never run against production data.
Paid accounts are unlocked by a verified payment webhook
Access should change only when your server receives a signed webhook from Stripe or your provider, not when the browser reaches a success page.
Top-rated companies
Ranked by our score: published prices, scope of work, AI tools named, timing and a low-risk first step. How we score.
- 1Afterbuild Labs10.0/10Best for: A check before launchFree first step · from $49
- 2Redlab10.0/10Best for: A full rescue by one team that keeps buildingFree first step · from $490
- 3Vibe Code Rescue (Lev Arakelyan)9.0/10Best for: A one-off check and a cleanupFrom $299
Related questions
My Lovable site is blank on my custom domain but fine on the lovable.app address. Why?
Usually the domain is not finished connecting, or the site was published before the domain was added. Check that Settings, Domains shows Live, then publish again. If it still fails, open the browser console on the custom domain and look for a blocked request.
Does moving my app to my own host change any of this?
It adds the host's own settings to the list. You must set the environment variables there, add the fallback rule for refreshes, and add the new domain to your auth provider. Lovable's docs say it cannot monitor or debug infrastructure it does not control, so testing is on you.
Sources: Lovable docs: Hosting and publishing; Lovable docs: Deploying and hosting outside Lovable; Replit docs: Development and production databases; Replit docs: About Deployments.
