views:

220

answers:

8

I'm wondering if the link on the company logo, which usually goes the home page, should be:

Does Google care or are there other rules?

+5  A: 

A or D.

Hard coding the full path in removes flexibility - let the web server or the app config handle what the default is.

(iirc google doesn't care any more than it would for any other link)

annakata
+2  A: 

Well, I would imagine that for simplicity's sake, it should just go to http://www.example.com. including index.html would make it dependant on the implementation of the home page being in index.html, which may not always be the case. Also, if you go off to some subdomain, you probably don't want to be redirected to the subdomain's homepage when clicking on the company logo, which as far as I've ever encountered, should always take you back to the main company home page.

Kibbee
A: 

I think you should set it to ~/

IIS / ASP.NET will translate that to your root automatically. i.e. http://www.example.com

This is perfect for testing locally too. On your local machine it will point to http://127.0.0.1/whateverYourPathIs, and when its deployed live, it will correctly point to http://www.example.com

Simon Hughes
+1  A: 

In my humblest of opinions and giving credit to my understanding to TBL, the URL should be identifying a resource and not so much the technical means by which it is generated: so I would argue against including 'index.html' in the link. After all, you're trying to point to the site at that address, and the fact that it's currently HTML (or that DirectoryIndex is set to 'index' on the apache server) is an implementation detail.

That leaves http://example.com and / to consider. I'm somewhat indifferent between the two. Is it possible the domain name where the current content is being served from will change? If it does, do I want to link to example.com or to the current domain? That's what I would be thinking about in deciding between the two.

Daniel Papasian
+1  A: 

If you're really trying to achieve proper SEO, I would think that you would rather have a logo or banner (something that's on every page to identify the website, not the page) be set as the background of a div instead of using <img>. I usually reserve <img> for images particular to the content on a specific page. This allows you to set the alt attribute as well which helps with SEO. As for the link, it really shouldn't matter to Google. I'm sure they've handled this on their end.

Joe Philllips
A: 

Relative URLs (C and D) would be resolved by clients (Google included) to absolute URLs (to B and A respectively) and therefore treated the same as their absolute counterparts. If your A permanently redirects to B, or B to A, then Google will also treat this as one resource. Google will score A+B+C+D as one page.

Whichever one URL the others eventually resolve or redirect to will be considered the 'canonical' URL.

The words contained in your canonical URL are important. As in the URLs of questions here on stackoverflow, the words should relate to the content. Therefore what you need to decide is whether or not you want the words 'index' and 'html' in the URL. I believe best practice for home pages is to have http://www.example.com/index.html permanently redirect to http://www.example.com/ .

Of course, content is still king, and all of this is just minor tweaking compared to adding quality content.

Liam
+1  A: 

ok simply put a never link to http://www.example.com/index.html as later you might use http://www.example.com/index.php if you change hosting or site design

equally never link to http://www.example.com as this is not a url and your browser must repair it

when linking from other company sites via logo link to http://www.example.com/ note the / as this is the actual url for {default page in first folder}

or internally on same site just link to "/" as this also means {default page in first folder on this site} which will keep your links working if company name changes

also ensure that http://example.com/ 301 redirects to http://www.example.com/ {and dosn't server identical content} and if many links are already to http://www.example.com/index.html first fix all you can second move index.html to index.htm then 301 redirect /index.html to http://www.example.com/ thus ensuring everyone eventually notices the http://www.example.com/index.html is gone

without loosing hits or PR

Alan Doherty
+1  A: 

I would and do go to /

My PHP/xHTML looks like this

<a href="<?php echo CONFIG_DIR_BASE ?>" title="Site Home">Home</a>
alex