X
    Categories: GoogleSEO

Google: Relative Versus Absolute URLs for SEO

Every once in a while, the whole relative versus absolute URLs and what is best for Google and/or SEO is debated within the community.  And the question came up again on Twitter where John Mueller from Google addressed absolute versus relative URLs from a few different SEO related perspectives.

First, relative versus absolute URLs refers to how they are coded in links.  Linking to http://www.example.com/somelink.html would be an absolute URL, while /somelink.html would be a relative URL.

John Mueller stated it does not make a difference for SEO.

It can be much easier to site migrate sites that are using relative URLs, as when you change the domain name or change from http to https, the internal links will continue to work without having to pass through a redirect chain until those links get updated with the new URL.

However, it is quite easy for site owners, especially novice site owners, to mess up relative URLs causing a crawling issue because the relative URLs were done incorrectly, such as being relative to an internal directory when it should have been mapped to the route.  So for this reason, many site owners simply link to the absolute URL to prevent any incorrect links or just from an ease of copying a page link without having to cut it down to a relative link, and ensure it is mapped correctly.

Then someone in an unrelated question asked about the fact relative links can sometimes result in a lot of 404 errors.  But Mueller says that both relative and absolute work as long as implemented correctly.

He also says that many problems are a result of URL rewriting done wrong.  And that if it is done incorrectly, it isn’t just a Googlebot problem, but a problem all crawlers will have.

But regardless, using either is fine for SEO purposes.  And crawling your own site – especially after a major structure, URL or site change – can often reveal problems that Googlebot will also have, whether it is an issue with incorrectly done relative URLs or a myriad of other issues that can be discovered with a crawl of the site.

 

The following two tabs change content below.

Jennifer Slegg

Founder & Editor at The SEM Post
Jennifer Slegg is a longtime speaker and expert in search engine marketing, working in the industry for almost 20 years. When she isn't sitting at her desk writing and working, she can be found grabbing a latte at her local Starbucks or planning her next trip to Disneyland. She regularly speaks at Pubcon, SMX, State of Search, Brighton SEO and more, and has been presenting at conferences for over a decade.
Jennifer Slegg :Jennifer Slegg is a longtime speaker and expert in search engine marketing, working in the industry for almost 20 years. When she isn't sitting at her desk writing and working, she can be found grabbing a latte at her local Starbucks or planning her next trip to Disneyland. She regularly speaks at Pubcon, SMX, State of Search, Brighton SEO and more, and has been presenting at conferences for over a decade.