HTTP status codes are how the web signals errors and other states from the server to the web browser. If there is an error from your backend website, the error is simply forwarded by Layer0 to the browser.

If the error is generated in Layer0 itself, the platform generates a 53x or 54x HTTP status code:

CODENAMEDESCRIPTION
412Precondition FailedThis code is returned when query string parameter layer0_prefetch equals 1 and the result is not found in the edge cache.
530Internal Layer0 ErrorUnexpected error in Layer0. Please contact support.
531Project Upstream TimeoutYour project timed out while waiting for an upstream response.
532Project Response Too LargeYour project returned a response size greater than the allowed 6MB.
533ReservedNot used by Layer0 at this time.
534Project Unexpected ErrorYour project's serverless code has failed unexpectedly. Use server logs to debug.
535Unknown ProjectThe HTTP header host is missing or does not match any Layer0 deployment. Check your requesting URL and your project config.
536ReservedNot used by Layer0 at this time.
537ReservedNot used by Layer0 at this time.
538Project Request LoopThe Layer0 project exceeded the maximum level (4) of nested Layer0 requests. “Nested” means an Layer0 site is the upstream of itself or of another Layer0 site.
539Project TimeoutYour project's serverless code did not respond on time, either due to slow upstreams or to badly handled asynchronous requests in code (e.g. missing await or call to callback). Use server logs and performance profiling to debug.
540Out of MemoryYour project's serverless code caused an out-of-memory situation. Please contact support.
541Layer0 Out of WorkersThe traffic was so high that request could not be scheduled for processing within the scheduling timeout. Please contact support to upgrade your account.
542Project Header OverflowThe Layer0 project's request or response had too many HTTP headers. See limits

Obviously, your project can set status codes of their own, which may sometimes match codes above. We encourage you to avoid that to lower the troubleshooting overhead and other issues.

Layer0 also issues these standard response codes:

CODENAMEDESCRIPTION
400Bad RequestThe URL is too long or the request headers are too large. See limits
404Not FoundThe server cannot find the requested resource. This usually occurs when the browser requests a page that your app does not have. It will also occur when a request does not match any of the routes in your Layer0 router. See routing for more information.
412Precondition FailedThe query string parameter layer0_prefetch equals 1 and the result is not found in the edge cache.
503Service UnavailableYour project's upstream was unavailable. See routing