Site logo

Archived topic

404 template

6 replies · Started by Dan on April 25, 2022

Viewing posts 1–7 of 7

Hi,
When creating a custom 404 template, as described here: https://generatepress.com/forums/topic/404-template/ or other examples in the forum, does the page have any indication that this is a 404 page? Does it add a .htaccess line indicating that this is the 404 error page? for the sake of search engines, analytics etc...

Thanks
Dan

Hi Dan,

The way described in your link should not change any default 404page information in terms of SEO.

so an http 404 error response code is added to that page template?

The template created by block element is just for the content of the 404 page.

It doesn't change anything else.

Hi Dan,

I had just set up a custom 404 page in the same manner you linked to. Since I had my local test site running, I checked this quick.

Basically, WordPress handles all incoming requests, including 404's, so an .htaccess line isn't necessary. In this case, WordPress will return the correct status code 404 for the requested url.

The only difference is it will now serve your custom template, instead of the default, along with the proper 404 error response code.

Ying is spot on correct :)

Hope this helps.

Thank you Jeremy, thank you Ying

You are welcome Dan!

Thanks for your help Jeremy :)

This archived topic is closed to new replies.