Something went wrong in the App Hosting build or rollout process. Look at the logs to see more details.
Hello! Oh, that’s one of the most frustrating errors to see.
It’s the general “something went wrong” message, and you’re right, the key is to find the real error in the logs.
This PUBLISHING FAILED error almost always means one of two things:
-
A Build Failure: Your code failed to build (like an
npm run builderror, a missing package, or a TypeScript error). -
A Rollout Failure: The build worked, but the app failed to deploy and start up (e.g., it crashed on start, or didn’t respond to the health check).
The logs will tell us exactly which one it is.
How to Find Your Build Logs
Here is the best way to find the specific error message:
-
Go to your Firebase Console (console.firebase.google.com).
-
In the main menu, go to Build > App Hosting.
-
You should see your App Hosting backend listed. Click on it to open its dashboard.
-
This will show you a history of your deployments (“rollouts”). The one that failed will be at the top, marked in red.
-
Click the three-dot menu (⋮) on that failed rollout and select “View build logs”.
What to Look For in the Logs
When you open the logs, don’t be overwhelmed! Scroll to the very bottom. The real error message is almost always in the last 10-20 lines.
-
Look for things like
npm ERR!(this means a package failed to install). -
Look for
Error: build failedor a specific TypeScript/linting error. -
Look for
Health check failed(this means your app crashed on startup).
If you can find that specific error message, please post that part of the log here. That will let us see the exact problem (e.g., a missing npm script, a build error, etc.) and get you a fix much faster.
We’re here to help!