Fix for Sitemap 404 Error in WordPress SEO by Yoast on Nginx

yoast seo 404 sitemap error thumb Fix for Sitemap 404 Error in Wordpress SEO by Yoast on NginxThis one’s a small post  about how to get rid of the 404 error you get when you try to check your sitemap_index.xml generated by Yoast WordPress SEO plugin , well this can be due to several reasons , so I will present a checklist of fixes for the 404 to go away ,



Initially I will suggest to take a look at Joost De Valk’s Blog post here at ,


Here’s the excerpt from above Post which talks about the 404 error ,


Why do I get a 404 when opening the sitemap_index.xml file?
You probably have W3 Total Cache active, that is preventing 404 errors for static files to go through to WordPress. Update to the latest version of W3 Total Cache or add, under the browser cache page, this exemption:



Now, I have notified him of the fix apart from what all methods he has written there but in case if he’s too busy making awesome plugins for us I thought I will share the solution for this 404 error with you here , Well all you have to do is edit your nginx configuration file for the affected domain and add this directive at the end within your server configuration , before you close the braces.


error_page 404 /index.php;


what this does is redirects all 404’s to index.php which is what WordPress does by default in a Apache server but in Nginx we need to put this and so once WordPress  receives the 404 error on it’s index.php then from there the Yoast SEO plugin does the redirection magic and you are served with your sitemap.


Hope it helped and those who are having problems applying this fix, just comment here and I’ll be happy to help .

About author
Computer Science Engineer by Education & a Programmer, Entrepreneur , Photographer by hobby & Passion who spends most of his time with his Computer/Mobile or his Camera - a Rebel t2i .
Submit your comment

Please enter your name

Your name is required

Please enter a valid email address

An email address is required

Please enter your message

People Found this Page by Searching Any of the Following in Google :

 yoast xml sitemap 404,  nginx symbian mobile fix,  sitemap xml wordpress 404,  sitemap yoast 404 iis,  wordpress yost seo nginx,  yoast nginx sitemap,  yoast seo sitemap 404,  как исправить sitemap yoast

TechStroke © 2014 All Rights Reserved

Powered by WordPress