Do I have to Link a Sitemap.xml

by gb530
22 replies
  • SEO
  • |
Hello Everyone,

This is my first post ever on Warrior Forum. I am excited to be here.

Anyways, I prob have one of the most noob questions around. I am setting up a site for SEO and just created a "sitemap.xml" and placed it in the root. Do I have to have "a href" link going to the file so search engines can pick it up? or do the engines already check the root for that file? ... If I have to link, can I just skip adding a hard link on the site and just put something within the header so it can be detected?

Thanks
#link #sitemapxml
  • Profile picture of the author abdul786
    Mentioning in header is enough for search spiders to know. Welcome to WarriorForum
    {{ DiscussionBoard.errors[7513583].message }}
    • Profile picture of the author gb530
      Thanks. Will placing the following code within the header work?

      <link href="http://domain.com/sitemap.xml" />
      {{ DiscussionBoard.errors[7513595].message }}
  • Profile picture of the author webss
    You can add it to your robots.txt file at the begginng of it to inform search engines. Dont forget a video sitemap as well if you use vid's.
    {{ DiscussionBoard.errors[7513859].message }}
  • Profile picture of the author webss
    I forget to mention in my last post, if you are using, say Wordpress and a sitemap generating plugin it may be taking care of it for you.
    You also can submit it to goggle and bing through webmaster tools.
    {{ DiscussionBoard.errors[7513878].message }}
  • Profile picture of the author Microsys
    Just add a reference to it in your robots.txt file:
    Code:
    Sitemap: http://www.example.com/sitemap.xml
    If possible also submit it in Google Webmaster Tools and Bing.

    You can check this article XML Sitemaps Submission and Robots Text File for details on both things.
    {{ DiscussionBoard.errors[7514464].message }}
  • Profile picture of the author jipolis7
    Actually without a sitemap your website is not a completed one today. Actually for four main reasons you should apply sitemap for your website -
    1. Navigations
    2. Theme
    3. Search Engine Optimization
    4. Organization
    Incorporating a site map into your Web site is a great way to keep your site easily accessible and neatly organized for everyone
    Signature
    {{ DiscussionBoard.errors[7515768].message }}
  • Profile picture of the author gb530
    Ok, I don't have a robots.txt file on the site because Ive never had a reason to exclude or tell engines what to do. If I do, I usually use meta in the header. Something like:

    <meta name="robots" content="nofollow" /> (Is this not recognized as much as a robots.txt file?)

    I guess I should start implementing robots.txt file so it will be site wide and not within each header.

    BUT hypothetically. The site I'm working on is a WP site and since everything is interlinking PHP files, can't I just place a small line of code within the header.php file so the sitemap can be detected. What code would I place in the header? Would the following code work?

    <link href="http://domain.com/sitemap.xml" />
    {{ DiscussionBoard.errors[7516399].message }}
    • Profile picture of the author JDIZM
      Originally Posted by gb530 View Post

      Ok, I don't have a robots.txt file on the site because Ive never had a reason to exclude or tell engines what to do. If I do, I usually use meta in the header. Something like:

      <meta name="robots" content="nofollow" /> (Is this not recognized as much as a robots.txt file?)

      I guess I should start implementing robots.txt file so it will be site wide and not within each header.

      BUT hypothetically. The site I'm working on is a WP site and since everything is interlinking PHP files, can't I just place a small line of code within the header.php file so the sitemap can be detected. What code would I place in the header? Would the following code work?

      <link href="http://domain.com/sitemap.xml" />
      Since your using WP then just download a sitemap plugin. There are some good ones that handle all of this for you.
      {{ DiscussionBoard.errors[7516414].message }}
  • Profile picture of the author gb530
    Hey JDIZM, thanks for the reply! I'm sure there are many plugins for WP but I don't always built sites within WP. So, would the code above work or not? I just want a simple one liner I can throw in the header for my sitemap to be recognized.

    I really appreciate all the feedback!
    {{ DiscussionBoard.errors[7516423].message }}
  • Profile picture of the author gb530
    Anyone?............
    {{ DiscussionBoard.errors[7528021].message }}
  • Profile picture of the author gb530
    just wondering if placing the following code will get my sitemap recognized?

    <link href="http://domain.com/sitemap.xml" />
    {{ DiscussionBoard.errors[7528152].message }}
  • Profile picture of the author Microsys
    No, as the earlier linked article states, that is not the way. You should instead include a reference to your xml sitemap file in the robots.txt file and/or submit your XML sitemap in Google Webmaster Tools
    {{ DiscussionBoard.errors[7530276].message }}
  • Profile picture of the author thatdude123
    I've downloaded a XML plugin for Wordpress but "Bing Webmaster tools sends me an email everyday saying I have none. I don't get it ??? Google picked it up fine but bing won't !

    The plugin clearly states its for google yahoo bing.

    Wher am I messing up ??
    {{ DiscussionBoard.errors[7531650].message }}
  • Profile picture of the author gb530
    got it sitemapper, thank you for the advice and the link above. Besides putting an <a> link on the site, it seems kind of strange to me that there are only two ways to get your sitemap picked up either through creating a robots.txt file or manually submitting.

    Thatdude, maybe try a different plugin. That's kind of why I don't want to use a plugin. I also like to just do things myself and I don't use WP for all my sites

    Creating s robots.txt file will be my solution and I will also manually submit.

    THANKS EVERYONE!
    {{ DiscussionBoard.errors[7533184].message }}
  • Profile picture of the author mikedex
    XML sitemap is for search engines. You just put them in your website root section.
    {{ DiscussionBoard.errors[7533225].message }}
  • Profile picture of the author gb530
    Wait, what? ... Your saying I dont have to link, put in my robots.txt file, or submit to get my sitemap.xml file noticed?.... Just place it in the root?
    {{ DiscussionBoard.errors[7533272].message }}
  • Profile picture of the author Stuart william
    There is no need of adding a link to sitemap but if you want then you can provide the reference in Robots.txt file to your sitemap.
    {{ DiscussionBoard.errors[7533907].message }}
  • Profile picture of the author kimseo
    Originally Posted by gb530 View Post

    Hello Everyone,

    This is my first post ever on Warrior Forum. I am excited to be here.

    Anyways, I prob have one of the most noob questions around. I am setting up a site for SEO and just created a "sitemap.xml" and placed it in the root. Do I have to have "a href" link going to the file so search engines can pick it up? or do the engines already check the root for that file? ... If I have to link, can I just skip adding a hard link on the site and just put something within the header so it can be detected?

    Thanks
    You don't have to link sitemap.xml. Just submit it to google webmaster tool(although that's also not required if page depth is reasonable).
    Signature
    {{ DiscussionBoard.errors[7534107].message }}
  • Profile picture of the author gb530
    That's what I thought. Just to triple verify, so if if place my Sitemap.xml file into my root folder, I don't need to link it because engines already look for it there?
    {{ DiscussionBoard.errors[7535147].message }}
  • Profile picture of the author ProSence
    It would be better if you submit manually your sitemap to each search engine, and use a sitemap is default for all the search engine, it shouldn't be too complected, Google provides tool to create sitemap as well.
    Signature

    three great FREE tools - www.sitebeak.com, www.GAtective.com and www.impersonal.me

    {{ DiscussionBoard.errors[7535159].message }}

Trending Topics