My Jekyll site 404 is not working

I’m facing an issue where my Jekyll site 404 page isn’t really working.
When visiting /404/ it works but when page doesn’t exist it shows the default Netlify 404.

My site url: https://nigerian.netlify.app

Hi @shoaiyb,

I visited https://nigerian.netlify.app/404/ and got a different 404 page than what Netlify serves. Have you managed to fix this?

Yes, I created 404.html file in the root project. And netlify generate /404/index.html which makes /404/ and 404 header to have difference.
Try visiting page that doesn’t exist, for example: https://nigerian.netlify.app/page/not/found.html

Have you tried setting a custom 404 (see docs) @shoaiyb?

Hi @shoaiyb,

It’s not something Netlify is doing magically. Jekyll is probably configured to generate the page at /404/index.html. It’s the same like what Hugo does.

You simply need to add a redirect rule as @coelmay mentioned.