Skip to content

Creating Custom Error Pages in NodeJS

Original guide · All levels

You can easily create custom 404 (Not Found) and 500 (Internal Server Error) error pages for your NodeJS application and style them as you need.

You can easily create custom 404 (Not Found) and 500 (Internal Server Error) error pages for your NodeJS application and style them as you need.

Creating custom error pages is as easy as creating a page called 404 or 500 in Wappler and adding content to it. These pages will be used as default error pages.

Open Pages and add a new page:

Add whatever content you want to show on this page. We simply add a heading, paragraph and a link that allows the users to go back to home page:

And you are done. Let’s preview the results, by entering a non-existing URL:

Section titled “And you are done. Let’s preview the results, by entering a non-existing URL:”

It’s quite similar for the custom error 500 page.
Open Pages and add a new page: