Base href
-
I'm having a discussion with a third party that's building a website for a client that I advised concerning his SEO.
The site went live 2 weeks ago and it's not getting indexed very well, so my client asked me what could be the problem.
I checked several things that could be the problem, like an xml sitemap that was missing etc. But there was another thing that I saw in the source code:
<base href="http://www.domain.com/">
Can this be a problem for Google to follow internal links? I always thought that you should use the base href like this:
<base href="http://www.domain.com"> so without the trailing / behind the TLD
And even better using absolute instead of relative links, no?
-
I suggest looking through previous Q&A forum results for various answers that have been provided for this question. Here's the query to find them: https://www.google.com/search?q=seomoz+base+href.
Basically, you are right, you should use absolute links instead of relative links. You only need to use a base href if you are using relative URLs on page and the base href is needed for them to resolve correctly.
The base href you are seeing in the code shouldn't be causing any issues for Google when following internal links. The issues, if any, would be caused by the relative links themselves if they are not set up correctly (this should be easily tested).
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Nofollow versus data-href
We have a couple of Tier-1 websites that contain a lot of affiliate links. These outgoing affiliate links currently have the rel="nofollow" element. Yet, I am seeing a lot of other websites and competitors, use data-href="" instead of nofollow. Is the latter better for SEO purposes or are they just using data-href for better tracking?
Technical SEO | | LoyensT0 -
What is the best way to redirect visitors to certain pages of your site based on their location?
One website I manage wants to redirect users to state specific pages based on their location. What is the best way to accomplish this? For example a user enters the through site.com but they are in Colorado so we want to direct them to site.com/colorado.
Technical SEO | | Firestarter-SEO0 -
GWT giving me 404 errors based on old and deleted site map
I'm getting a bunch of 404 crawl errors in my Google Webmaster Tools because we just moved our site to a new platform with new URL structure. We 301 redirected all the relevant pages. We submitted a new site map and then deleted all the site maps to the old website url structure. However, google keeps crawling the OLD urls and reporting back the 404 errors. It says that the website is linking to these 404 pages via an old outdated sitemap (which if you goto shows a 404 as well, so it's not as if Google is reading these old site maps now). Instead it's as if Google has cached the old sitemap but continues to use it to crawl these non-existent pages. Any thoughts?
Technical SEO | | Santaur0 -
Content Based on User's IP Address
Hello, A client wants us to create a page on two different sites (www.brandA.com/content and www.brandB.com/content) with similar content and serve up specific content to users based on their IP addresses. The idea is that once a user gets to the page, the content would slightly change (mainly contact information and headers) based on their location. The problem I am seeing with this is that both brandA and brandB would be different Urls so there is a chance if their both optimized for the similar terms then they would both rank and crowd up the search results (duplicate content). Have you seen something similar? What are your thoughts and/or potential solutions? Also, do you know of any sites that are currently doing something similar?
Technical SEO | | Rauxa0 -
SEO Ramifications of migrating traditional e-commerce store to a platform based service
Hi I'm thinking of migrating my 11 year old store to a hosted platform based e-commerce provider such as Shopify or Amazon hosted solutions etc etc I'm worried though that will lose my domains history and authority if i do so Can anyone advise if this is likely or will be same as a 301 redirect etc etc and should be fine ? All Best Dan
Technical SEO | | Dan-Lawrence0 -
Duplicate Content based on www.www
In trying to knock down the most common errors on our site, we've noticed we do have an issue with dupicate content; however, most of the duplicate content errors are due to our site being indexed with www.www and not just www. I am perplexed as to how this is happening. Searching through IIS, I see nothing that would be causing this, and we have no hostname records setup that are www.www. Does anyone know of any other things that may cause this and how we can go about remedying it?
Technical SEO | | CredA0 -
Redirection based on country and impact on rankings
I have a website that ranks number 1 in google.co.uk for its main key term and ranks number 4 in google.com.au. However i would rather that visitors in australia see domain.com.au rather than domain.co.uk. Is there a way to achieve this using some clever 301s without impacting the rankings in australia and so that the .com.au starts to rank in place of the .co.uk OR Would you advise launching a .com.au version of the site hosted separately with unique / re-written content on it.?
Technical SEO | | thefresh0 -
Does Google follow a text based URL with no anchor tags?
I am seeing with Webmaster Tools that Google is trying to follow the text based truncated URL from SuperPages despite the fact that they are not in an anchor tag. The net result for Google is a 404 error as they try to access pages that do not exist. has anyone seen this issue before and any suggestions on how to prevent these errors? A Superpage listing: The first link works fine, but the text based link shown below is cut off and as a result Google gets to a 404 page. http://swbd-out.superpages.com/webresults.htm?qkw=dr+hylton+lightman&qcat=web&y=0&x=0& Dr. Hylton Lightman, MD - Pediatrician, Allergist, - Far Rockaway ... Dr. Hylton Lightman, MD, Far Rockaway, NY, Rated 4/4 By Patients. 26 Reviews, Patients' Choice Award Winner, Phone Number & Practice Locations www.vitals.com/doctors/Dr_Hylton_Lightma... [Found on Bing]
Technical SEO | | irvingw0