I uploaded my sitemap.xml to my Index of folder.

enter image description here

I tried to open sitemap.xml by example.com/sitemap.xml but it won't work.

If I try with example.com/wp-admin/sitemap.xml it will open my sitemap.xml.

I want to open my sitemap.xml by using this link example.com/sitemap.xml only but where can I find the root folder? Where do I need to place my sitemap.html file?

3 Answers 3


The root of your site is where the wp-admin, wp-content and wp-includes folder is. From what you are showing in the image this does not appear to be the actual root directory of your Wordpress installation.

You could make this easier with the plugin mentioned by the other answer but if you are looking for something more custom then you'll need to find the actual root.


Difference between Site Root and WordPress Root

It's important to differentiate between both variants. The Root of your Domain/Website depends on the settings of your webhost. Some might give you ftp access to directories above the web root, and some might put you directly in the web root when accessing your ftp data. When you upload a file for testing, and it is available on yourdomain.com/yourfile.txt, that directory is the webroot. You can put your WordPress installation in this directory or any directory below. For Example your whole WordPress installation can be in yourdomain.com/sub/directory/blog, if this makes any sense to you.

In this case your Web root would still be yourdomain.com, while your WordPress root would be yourdomain.com/sub/directory/blog.

Inside your WordPress Directory you will have additional folders like wp-admin, wp-includes, wp-content. It looks like you uploaded your file into wp-admin.


When you say you upload your sitemap I assume you have generated that locally. Just let me note that it is totally possible, and good, to let a WordPress plugin do this job, assuming you are using only WordPress for your content. There are several Plugins out there doing this job (one example would be XML Sitemap & Google News). This would probably make things easier.

So you could upload your file into another directory (once you find out where your webroot is) or use a WordPress plugin to generate the sitemap for you.


Where I can find the root folder?, Where I need to place my sitemap.xml file?

The root folder is the folder that is the top most directory of your project. Root directory contains your wp-config.php file. The sitemap.xml needs to be in root directory only.

If you are using Wordress then you don't need to create your sitemap. There is a plugin called Google XML Sitemap which will do your work.

This plugin creates the sitemap in your root directory i.e www.example.com/sitemap.xml so that the search engine will index your site better.

So whenever you have created a post or page, the sitemap will automatically get updated with the latest content.

If you have further query please go through their FAQ.

  • I'm facing problem with using plugins. By using plugins I don't get xml format response
    – Athavan
    Commented Jul 22, 2016 at 13:35
  • Can you please let me know which plugin you are using. The plugin which I have recommended ?
    – Aftab
    Commented Jul 22, 2016 at 13:37
  • I used google sitemap. It does not return xml format output. There is any way to get the sitemap.xml without plugins? Otherwise how can I get the xml format output using plugins? wordpress.stackexchange.com/questions/232839/…
    – Athavan
    Commented Jul 22, 2016 at 13:49
  • Have you activated the plugin. If yes , can you go to Setting > XML Sitemap and choose the option. Please go through the FAQ question answer section for this plugin wordpress.org/plugins/google-sitemap-generator/faq
    – Aftab
    Commented Jul 22, 2016 at 13:56
  • "The root folder is the folder that is the top most directory of your project. Root directory contains your wp-config.php file. The sitemap.xml needs to be in root directory only." Where I can find that root folder? Index of is the Top most Directory Right? In Index of folder I can't able to find the wp-config.php file.
    – Athavan
    Commented Jul 22, 2016 at 22:54

Not the answer you're looking for? Browse other questions tagged or ask your own question.