Lovable app showing a blank white screen — how to fix it
Your Lovable app opens to an empty white page. Here's how to find the real error in two minutes and fix the usual causes: missing env vars, a bad change, a paused Supabase project, stale files.
6 min readLovableFixesBlank screen
You open your Lovable app and get… nothing. No error, no spinner, no text. Just a white page. Visitors see the same thing, and most of them leave without telling you.
A blank screen almost never means "the server is down". The server answered fine. It sent your app's HTML and JavaScript to the browser, and then the JavaScript crashed before it drew anything. That's why ordinary uptime checks say everything is up while your users stare at a white page.
The good news: the browser knows exactly what went wrong. You just have to look in the right place. This guide walks you through finding the error, then fixing the causes we see most often in Lovable apps.
Step 1: Make sure it isn't Lovable itself
Before you change anything, check whether the problem is on Lovable's side. If Lovable's hosting or its publishing pipeline is having trouble, nothing you change in your project will help, and you might break something that was fine.
- Look at our live Lovable status page. It shows what Lovable's own status page says and what our check sees, updated every 5 minutes.
- If your app uses Supabase (most Lovable apps do), check Supabase status too.
If either is having an outage, wait it out. If both are fine, the problem is in your app — keep reading.
Step 2: Read the real error in the browser console
This is the single most useful thing you can do, and it takes a minute.
- Open your published app on a computer, in Chrome, Edge or Firefox.
- Right-click anywhere on the white page and choose Inspect. (Or press F12. On a Mac: Cmd + Option + I.)
- Click the Console tab.
- Reload the page.
Red lines are errors. The first red line is usually the cause; the rest are often side effects. Copy the full text of the first one. You'll use it in the next steps — and if you ask Lovable to fix it, the exact message makes all the difference.
Also click the Network tab and reload once more. Any request in red (a failed request, or a status code like 401, 404 or 500) is a strong clue, especially if it goes to supabase.co.
Step 3: Match the error to its fix
"supabaseUrl is required" or anything about an undefined Supabase URL
Your app tried to connect to Supabase without knowing the address. The Supabase client throws an error at startup, and because it happens before anything is drawn, the whole page stays white.
Lovable apps read the Supabase address and key from environment variables that start with VITE_ — for example VITE_SUPABASE_URL and VITE_SUPABASE_PUBLISHABLE_KEY. Lovable's documentation says these frontend variables live in the project's .env file and are built into the app when it's published, so they're meant to be public. (Secret keys are a different story — see our guide on exposed API keys in Lovable apps.)
How to fix it:
- Published on Lovable: make sure the Supabase connection is still set up in your project and publish again. If you or the AI edited
.envor the Supabase client file recently, check that the values are still there. - Deployed to Vercel or Netlify: those hosts don't see Lovable's settings. Add every
VITE_variable from your.envto the host's environment variable settings, with exactly the same names, then redeploy. On Netlify that's Site configuration → Environment variables; on Vercel it's Project → Settings → Environment Variables. A variable added after the build isn't in the app until you build again.
"Failed to fetch dynamically imported module" or a "Loading chunk failed" error
Lovable apps are built with Vite, which splits the code into files with names that change on every publish. If a browser still has the old page open, or cached the old index.html, it asks for files that no longer exist.
- Do a hard refresh (Ctrl + Shift + R, or Cmd + Shift + R on a Mac) and try a private window.
- If it works in a private window, it's a caching issue. It goes away for visitors as their cached copy expires, but it can come back after every publish. You can ask Lovable to "reload the page once when a dynamically imported module fails to load", which is a common fix for this.
A TypeError like "Cannot read properties of undefined"
Something in your code expects data that isn't there — an empty API response, a user who isn't logged in, a renamed field. These usually appear right after a change.
The fastest fix is to go back to the last version that worked:
- In Lovable, open the project's version history.
- Preview older versions until you find one that works.
- Restore it.
Lovable's docs note that restoring brings back the code only — your database data isn't rolled back. That's usually what you want: the data is fine, the code broke.
Then re-apply the change you wanted in smaller steps, and test the preview after each one.
A 401 or "Invalid API key" from Supabase
The app reached Supabase, but Supabase didn't accept the key. This happens after someone rotated or regenerated keys in the Supabase dashboard, or when an app points at one Supabase project with another project's key. Copy the current publishable (or anon) key from Supabase's API settings into your project's variables, then publish again.
Requests to supabase.co time out or fail, and nothing else is wrong
If your Supabase project is on the Free plan, it may have been paused for inactivity. A paused project doesn't answer, and an app that waits for data before drawing anything can end up white. Open the Supabase dashboard: a paused project says so and offers a restore button. Our guide on restoring a paused Supabase project has the details, including how to stop it from happening again.
The page is white only on some addresses, or after a refresh
If the home page works but yourapp.com/dashboard is blank or shows a 404 when you open it directly, your host isn't sending all addresses to the app. That's a single-page-app routing setting, and it mostly happens when the app is deployed outside Lovable:
- On Netlify, add a
public/_redirectsfile with the line/* /index.html 200. - On Vercel, add a rewrite that sends every path to
/index.htmlinvercel.json.
Step 4: Ask Lovable to fix it — with the exact error
If none of the above matches, give Lovable's AI the facts instead of "my app is blank". Paste something like this:
My published app shows a blank white page. The browser console shows this error:
<paste the first red error here>
The failing network request is: <paste the URL and status code, if any>
Find the cause and fix it. Don't change anything unrelated. After the fix, the page should render even if this data is missing.
The last sentence matters. It asks for code that handles missing data gracefully instead of crashing the whole page.
Step 5: Stop one error from blanking the whole page
React apps (which is what Lovable builds) go fully white when a component throws an error during rendering and nothing catches it. An error boundary is a small wrapper that catches the error and shows a message instead, like "Something went wrong, please reload".
You can ask Lovable: "Add an error boundary around the app that shows a friendly message and a reload button instead of a blank page." Your users then see something useful, and you still see the error in the console.
How to know before your users do
Here's the uncomfortable part: a blank screen is invisible to normal uptime monitoring. The server returns "200 OK" with a valid HTML page, so the monitor says everything is up. The crash happens later, inside the browser.
To catch it, something has to open the page in a real browser and look at what's drawn. That's what Pingbuddy's blank screen detection does: on the Free plan a real browser opens your app every 30 minutes (every 10 on Pro), checks whether the page is empty, shows a JavaScript error or an "Invalid API key" message, and tells you on Telegram or by email with a screenshot. It also watches for new publishes, so if your app breaks right after you publish, the alert says so.
You can also run a free checkup of your app right now. It looks for problems like an expiring SSL certificate, keys left in public code and a paused Supabase project.
Quick checklist
- Check Lovable and Supabase status first.
- Open the console, copy the first red error.
- Missing Supabase URL → set the
VITE_variables (on Vercel/Netlify too) and rebuild. - Chunk loading error → hard refresh; ask Lovable to reload on failed module loads.
- TypeError after a change → restore the last working version, re-apply in small steps.
- 401 from Supabase → update the key.
- Timeouts to Supabase → check whether the project is paused.
- Add an error boundary so one bug can't blank the whole app.