Tell me more ×
WordPress Answers is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm getting errors in sitemap_index.xml which is xml generated by Yoast plugin.

Below is the error that I'm getting:

This page contains the following errors:

error on line 2 at column 6: XML declaration allowed only at the start of the document
Below is a rendering of the page up to the first error.

I know that there is a whitespace and I had a look at functions.php and other files but they all seem normal without any extra actions triggering whitespaces at the top.

I could probably disable and enable one plugin one by one and try it that way but is unsure whether this is a good option as there is a rist involved in losing plugin configurations or any setups done on the plugins when deactivated.

Does anyone have any suggestions?

share|improve this question
Your feeling is correct. You need to debug this and the place to start is with disabling plugins and switching to the default theme. – s_ha_dum Jan 4 at 14:47
can you show us the actual xml? – adrian7 Jan 6 at 14:00

closed as too localized by toscho Feb 9 at 11:56

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, see the FAQ.