My site is a blank white page after deploying. Why?

Also searched as: React app showing blank page after deployment · Angular white page after deployment · Website showing blank page after deploy in React · Blank page after deploy React / Vite app to Vercel

Updated 3 October 2026

Short answer

The page loaded, but the app inside it didn't start. Open the browser's developer tools on the blank page (F12, then Console): the red error there names the cause. Usually the app's files are being fetched from the wrong path, a setting it needs was blank when it was built, or the host isn't set up to serve the app's other pages.

What's the problem

The deploy says it succeeded. The address loads. And there's nothing: a white page, maybe with the right title in the browser tab. Or the home page works, but refreshing any other page gives a 404.

Why it happens

Most modern web apps send the browser an almost empty page plus a bundle of JavaScript that draws everything. If that JavaScript doesn't load, or crashes as it starts, all that's left is the empty page.

  • Files requested from the wrong path. If the app lives in a subfolder (for example on GitHub Pages, at /your-repo/) but was built to expect the root of the domain, the browser asks for its JavaScript in the wrong place and gets nothing. Tools such as Vite and Create React App need to be told where the app will live.
  • A setting was blank at build time. An API address or service key that existed on your laptop but not on the host. The app starts, reads an empty value, crashes, and leaves a white page.
  • The host doesn't know about the app's pages. The app handles its own pages in the browser, but when someone loads /dashboard directly, the host looks for a file called dashboard, finds none, and returns a 404. The host has to be told to serve the app's main page for every address.

How to fix it

  1. Open the console on the blank page. Note the first red error. Then open the Network tab and reload: any .js or .css files in red (404) mean a path problem.
  2. If files are 404, set the base path to where the site really lives (base in vite.config.js, or homepage in package.json for Create React App), then rebuild and redeploy.
  3. If the error mentions something undefined (a config value, an API URL, a key), add that setting to the host's environment variables and rebuild. Settings are baked in at build time.
  4. If only refresh breaks, add your host's rewrite rule for single-page apps so every address serves index.html. Netlify, Vercel and others document theirs.
  5. Test the production build locally before deploying, for example with npm run preview for Vite. It shows the same blank page if the build itself is broken.

When to call Preventionlabs

A blank page is usually one of these, and fixable in an afternoon. Call us when the console shows a wall of errors from code nobody understands any more, or every fix breaks something else. The first thing a resurrection delivers is an app that builds and starts, deployed in your own hosting account, with the user flows you list working end to end.

Submit your project for a free assessment

Free assessment. $10,000 AUD flat to get it live, only if we take it on and you go ahead.

Sources

  1. Vite: Deploying a Static Sitebuild tool docsIf you are deploying to https://<USERNAME>.github.io/<REPO>/ (eg. your repository is at https://github.com/<USERNAME>/<REPO>), then set base to '/<REPO>/'.
  2. Create React App: Deploymentofficial docsCreate React App uses the homepage field to determine the root URL in the built HTML file.
  3. Create React App: Deployment: Serving Apps with Client-Side Routingofficial docsThe server needs to be configured to respond to a request to /todos/42 by serving index.html.
  4. Netlify: Rewrites and proxieshosting platform docsIf you’re developing a single page app and want the history pushState method to work so you get clean URLs, you’ll want to add the following rewrite rule.
  5. Vite: Deploying a Static Site: Testing the App Locallybuild tool docsOnce you've built the app, you may test it locally by running npm run preview command.
← All of Getting it live