Forum Moderators: open
Ex:
is it better do use:
<a href=http://www.mysite.com/articles/seo-article.html>SEO Article</a>
or...
<a href="/articles/seo-article.html">SEO Article</a>
I have been having this discussion with my website designer and he says it doesn't matter. He says from an administration aspect, relational is better. I think this was discussed in the IMC training, but can't remember for sure.
Thanks,
Dave
There are some minor anti-spam implications, but the main reason is that absolute linking ensures that the SE bots crawl your site as easily as possible.
GoogleGuy commented on it years ago in this thread:
[webmasterworld.com...]
I would use a 301 redirect or rewrite so that your root page doesn't appear twice. For example, if you select http: //www.yourdomain.com/ as your root page, then if a spider tries to fetch
http: //yourdomain.com/ (without the www), your web server should do a permanent (301) redirect to your root page at http: //www.yourdomain.com/So the high-order bits to bear in mind are
- make it as easy as possible for search engines and spiders; save calculation by giving absolute instead of relative links.
- be consistent. Make a decision on www vs. non-www and follow the same convention consistently for all the links on your site. Use permanent redirects to keep spiders fetching the correct page.Those rules of thumb will serve you well no matter what with every search engine, not just with Google. Of course, the vast majority of the time a search engine will handle a situation correctly, but anything that you can do to reduce the chance of a problem is a good idea. If you don't see any problems with your existing site, I wouldn't bother going back and changing or rewriting links. But it's something good to bear in mind when making new sites, for example.
If you have a choice, which is most true in the initial development, it's better to go with absolute. Probably not worth going backwards though, and recoding an existing site, unless issues are apparent.
One thing you can do to help the SE's deal more effectively with relatively paths is to use the <base href=""> element in the head section of each page.