It builds on my machine and dies on deploy
This is the most common wall people hit after exporting from an AI builder. The editor had a dev server, your host does not. Five causes cover almost every case. Check them in this order — the first two are about eighty percent of what I see.
1. Environment variables exist locally, not on the host
Your .env file never leaves your machine. The host has its own copy, and it needs one for every environment.
In Next.js, browser code only sees variables whose names start with NEXT_PUBLIC_; in Vite, VITE_. Those values are copied into the public bundle at build time, so anyone can read them. Add the prefix only to values that are safe to publish — a site URL, a publishable or anon key — and change every place that reads them. A secret never gets the prefix: move the code that uses it to the server (cause 3).
2. The import works on Windows and fails on Linux
Your computer does not care about letter case in file names. The build server does. A file imported as ./Card that is really named ./card.tsx builds at home and fails in the cloud.
The same applies to folders, and to imports that resolve through an index file.
3. Server code is being called from the browser
AI builders happily write a database call or a secret-key call inside a component. It works while everything runs on one machine and breaks the moment the browser is the one executing it.
If a secret key was ever shipped in browser code, rotate it. Anyone who opened your site has it.
4. A package is installed locally but missing from package.json
Something got installed by hand during a debugging session and never written into the manifest. Your machine still has it; a clean install does not.
A lockfile that is out of date with package.json fails the build outright on most hosts.
5. The build command or output directory is wrong
The export assumes one framework preset; the host guessed another. The build passes and the host serves an empty directory, or the build never runs at all.
A build that succeeds with zero files in the output looks identical to a broken deploy. Check the file count in the build log.
Not one of these five?
Send me the link and the exact error text. I will tell you what is broken and what it would take to fix, in writing, within 24 hours. That part is free, and you are not obliged to hire me afterwards.
If you do want it fixed: emergency rescue starts at $600, and I name one fixed number before I start.
Send me the link