404 page without Node?

Just wondering, would it be possible to have a project with a custom 404 page without using nodejs? I tried using NodeJS to make a 404 and 500 page but some odd effects happened after I tried that. I would rather keep this project static.


I can’t think of a way to do this currently since it would require back end config not available on the static site projects.

What type of issues did you experience with the Node.js project?

Every page was the 404 page for some reason. Looking back I think it was because I had to set up a views folder and instruct the app to display static pages. I may take another look at it in the future however.

@RiversideRocks try using .htaccess file, example at https://glitch.com/~youngchief-btw-now-sh

I saw a thread but forgot the name where it had a link to a project where it had that file working because Glitch doesn’t support it by default or something.

1 Like

Oh interesting TIL! If you try this I’d love to know if it works.

Tried this with Github pages and it works fine

@RiversideRocks What to insert in the file

ErrorDocument 400 /400.html
ErrorDocument 500 /505.html

I actually think I got express working: For example:

1 Like

Fun fact: I somehow once got bored and used a cloudflare plugin or something and made the 404 page the glitch loading screen.