htmlsitemapsitemap.xml

sitemap.xml 404 error on one server, not on another?


I'm having a problem with my sitemap. I know I strictly don't need a site map as my site in question is only a single page, but when reading on the web some people say it's not necessary and other say it is, but that's by the by!

I created my sitemap manually and uploaded to a test server, everything was working well. I uploaded it onto the actual server and thought all would be fine. I run woorank's website review and it says that the sitemap doesn't exist. I did the woorank test on the test server and it found the server.

If I try and browse to the sitemap on the server I get a 404 error saying the file isn't found. Browse to the sitemap on the test server, displays it fine!

Thought it might have been the way I created, so used https://www.xml-sitemaps.com to create the sitemap, same issue.

Checked that the file is a text file.

Hostinger, the hosting company, says there shouldn't be an issue.

This is the sitemap.xml

<?xml version="1.0" encoding="UTF-8"?>
<urlset
      xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
            http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
<!-- created with Free Online Sitemap Generator www.xml-sitemaps.com -->


<url>
  <loc>https://www.xxxxxxx.co.uk/</loc>
  <lastmod>2019-12-10T21:38:07+00:00</lastmod>
</url>


</urlset>

Any body have any ideas? Thanks in advance!

Image of files in folder as requested

Files in folder


Solution

  • Solved my issue. Whilst trying to solve another issue, in my .htaccess file I came across some lines that were mentioning xml, some I commented them out and vola! Access to my xml file again!