Help for owners
My site stopped deploying on Vercel after an update
Short answer
Your live site keeps running while a new deployment fails. Open the failed deployment in the Vercel dashboard and read the build log, since the last line of the error is often not the real cause. Check that the project builds on a computer first. Do not change settings at random.
Does this sound like your situation?
- The Vercel dashboard shows a red Error next to my latest deployment.
- My change is not live and my developer says it builds on their machine.
- A deployment worked last week with no obvious change.
- The build ends with a line like exited with 1 and no explanation.
- There are no build logs at all, just an error message.
Why does this happen?
The real error is above the last line
Vercel's guide says the last mention of Error in the build log often is not the useful one, for example a line saying a build command exited with 1, and that the cause is usually a few lines above.
Confirmed by vercel.comTechnical detail: Vercel says npm run build exited with 1 and my deployment fails
The code does not build even on a computer
Vercel recommends building the project on your own machine before deploying, which catches issues in your code or its packages. An update that broke the build locally will break it on Vercel.
Confirmed by vercel.com
The build ran into a platform limit
Vercel states that every build container has fixed memory and disk space and that builds exceeding them are cancelled. A build can also last at most 45 minutes. A larger site or heavier packages can cross these limits after an update.
Confirmed by vercel.com
The build did not start at all
Vercel lists causes that give no build logs: an invalid vercel.json committed to the repository, Ignored Build Steps, commits from someone who is not a team member, or a connected Marketplace integration that failed to provision. The error then shows as a message on the deployment.
Confirmed by vercel.com
Case-sensitive file names
A file that loads on a Windows or Mac computer can fail on the build server if its capital letters differ.
Technical detail: Module not found on Vercel but the build passes on my machine
What can I do about it today?
- Confirm the live site is fineA failed deployment does not take the current site offline. Open your site to check, then continue calmly.
- Open the failed deploymentIn the Vercel dashboard choose the project, then Deployments, and select the one with the error. Copy the error text, and the lines above it, into a message to your developer.
- Find what changed since the last good deploymentNote the date of the last green deployment and everything done after: new packages, new settings, new team members, new connected services.
- Do not delete the project or its domainRemoving a project can take the live site down and lose environment settings.
- Do not paste secret keys into chat or emailIf someone asks for environment variables, share them through a password manager, not in plain messages.
- Redeploy only the last known good version if the site needs itVercel lets you redeploy an earlier deployment. Ask your developer before you do it, because it can also bring back older content.
When should I bring someone in?
- A fix to the site is urgent and the deployment keeps failing.
- Your developer is not available and nobody has access to the repository.
- The error mentions memory, disk space, or the time limit.
How do I handle it?
- Read the whole log, not the last lineI find the first real error in the build log and note which step failed: install, build or output.
- Reproduce it on a computerThe same commit is built locally with the same Node and package versions, which shows if the code or the platform is at fault.
- Compare with the last good buildPackages, settings and files changed since then are compared one by one.
- Fix the cause, not the symptomI avoid options that hide errors, such as skipping checks, unless the reason is written down.
- Leave a deploy checklistThe steps that worked are written down, with version pinning, so the next update does not break it the same way.
The price depends on what I find, so I quote in writing after a short discovery call. Tell me what is happening and I reply within 24 hours.
What do owners ask about this?
Is my website down?
Not because a deployment failed. The previous successful deployment keeps serving visitors until a new one succeeds. If the site is down, the cause is different.
Why is there no build log?
Vercel lists reasons: an invalid vercel.json, Ignored Build Steps, commits from someone who is not a team member, or an integration that failed to provision.
Can Vercel support fix it?
They can help with the platform. Errors in your own code or packages need your developer.
Sources
How was this page made?
I drafted this page with AI assistance from the official documents listed under Sources. Found a mistake? Tell me.
For your developer: the technical fixes
Error: Command "npm run build" exited with 1Vercel says npm run build exited with 1 and my deployment failsnpm ERR! code ERESOLVEnpm install fails with ERESOLVE during my Vercel deploymentModule not found: Can't resolveModule not found on Vercel but the build passes on my machine> Build error occurrednext build stops with: Failed to collect page data for a routeFATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memoryFATAL ERROR: heap out of memory during a webpack or npm build