Internal file extension canonicalization
-
Ok no doubt this is straightforward, however seem to be finding to hard to find a simple answer; our websites' internal pages have the extension .html. Trying to the navigate to that internal url without the .html extension results in a 404.
The question is; should a 401 be used to direct to the extension-less url to future proof? and should internal links direct to the extension-less url for the same reason?
Hopefully that makes sense and apologies for what I believe is a straightforward answer;
-
As above
example/abc rewrites to example/abc.html
example/abc.html redirects to example/abc
and all internal links link to example/abc
-
Thankyou for the replies.
I will try and clarify what I am trying to get at; apologies in advance for any naivety.
I understand homepage canonicalization; the confusion revolves around how this applies to internal pages.
Logically; I am struggling to see how internal pages are any different to a homepage in terms of the need to avoid multiple urls....and thus an extension-less url seemed appropriate. Not too mention the benefit or cleaner urls, easier to link to, remember etc.
i.e.
example/abc
example/abc.html
example/abc.index.html
-
As nick said, you dont need to do this, but if you are.
1. REWRITE the new url to the old url, as your webserver needs to know the extention
2. REDIRECT the old url to the new one, incase you already have links to the old urls, you dont want5 duplicate content
3. you need to make surer that all internal links point to the new url, you dont want un-necessary redirects as they leak link juice.
-
I'm about to make a whole lot of assumptions about your website to give this answer, just be aware.
Your website is built static, using HTML. Hence the .html file extension. If you're seeing websites that don't have file extension, it's most likely they are using content management systems (or have some serious /folder/index.html stuff going on).
Having a file extension like .html or .aspx or .php is not a bad thing. On websites like yours, it is required (unless you do the above subfolder thing) because it's an actual file the browser is grabbing rather than something being dynamically generated by a CMS. It has nothing to do with future-proofing.
As for 301'ing non-extension URLs to extention'd ones...well I don't know why you'd need to do that for your type of site.
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
-
Avoid too many internal links
My site is being flagged in Page Optimization Score for "Avoid too many internal links", but the warning doe snot tell me how many internal links are on a page. How can I find this?
Technical SEO | | Zambezikid0 -
Do old website files in the public_html effect SEO?
My client has about a dozen old folders filled with old websites including index files, robots, htaccess files. They are all located in separate files with in public_html. Does this effect them negatively?
Technical SEO | | Renalynd0 -
Google not returning an international version of the page
I run a website that duplicates some content across international editions. These are differentiated by the country codes e.g. /uk/folder/article1/ /au/folder/article1/ The UK version is considered the origin of the content. We currently use hreflang to differentiate content, however there is no actual regional or language variation between the content on these pages. Recently the UK version of a specific article is being indexed by Google as I am able to access via keyword search, however when I try to search for it via: site:domain.com/uk/folder/article1/then it is not displaying, however the AU version is. Identical articles in the same folder are not having this issue. There are no errors within webmaster tools and I have recently refetched the specific URL. Additionally when checking for internal links to the UK and AU edition of the article, I am getting internal links for the AU edition of the article however no internal links for the UK edition of the article. The main reason why this is problematic is because the article is now no longer appearing on the UK edition of the site for internal site search. How can I find out why Google is not getting a result when the URL is entered but it is coming up when doing a specific search?
Technical SEO | | AndDa0 -
Can the Hosting location of image files have a negative effect if on the developers own media server rather than on client site server ?
Hi Can the Hosting location of image files have a negative effect if on the developers own media server as opposed to on the actual websites server ? In the case i'm looking at the image files are hosted on a totally separate server (a media subdomain of the developers site server) from the subject sites dedicated server. Will engines still attribute the properties of files hosted in this manner to the main website (such as file name or should they really be on the subject sites server own media folder ? Cheers Dan
Technical SEO | | Dan-Lawrence0 -
Canonicalization Issue | E-commerce
Hey everyone! How are you doing? I spent this week trying to solve some technical issues on my website. However i am having trouble with Duplicate Content. I came to the conclusion that canonicalization is a great solution to this problem, however, i am having trouble implementing it. The duplicate problem arises from the fact that for each product i have several colors or different attributes. For example. I have the category "Construction Clips" and then links to "Color" in which the user can choose White or Sandstone. The content is almost identical for both of them, the only thing that changes is the color. This scenarios repeats many times throughout my webcommerce site. And is throwing me off many Duplicate Content errors. I cannot use the canonicalization in the White or Sandstone page, because is a product page, it doesnt let me add or change anything on the header. http://aceromart.com/Clip-Glamet-Blanco.aspx I dont intend to rank well on most product pages, my priority is that i dont want duplicate errors on my website. What is the best solution for this conundrum? Regards!!! In advance, i thank you for your opinions!
Technical SEO | | JesusD0 -
A query about internal linking. Have I got this right?
Hi Guys I think this sounds like a right noobie question, but I am amongst friends so here goes. So our website is an ecommerce site selling magazines. There are certain magazines, for example Vogue, where we sell the UK version, USA, italian, spanish, french etc there's basically 13 different Vogue magazines on our site. The more niche ones attract some good long tail traffic. However, the UK version is competitive and so requires some extra umph to get us a half descent rank. However, when you search "vogue magazine subscription" for example, it's our italian vogue which is listed first. When I looked into this, I found that we had linked out from our UK Vogue to Italian vogue. Could this have given the italian vogue a marginal boost, as it had the additional internal links? What I have now done is add to some, not all, of the variations something along the lines "you will find the UK Vogue magazine here" where "UK Vogue Magazine" is the anchor text. Is this the right thing to do? Will this identify that the UK Vogue page is the higher priority page, or the more important page? I was also going to add to a category page a "Top 10 Womens magazines" section, and link to Vogue from there. Am I barking up the right tree? Thanks Guys Paul
Technical SEO | | TheUniqueSEO0 -
Does anchor text penalty apply to internal links?
We already know that over optimsied anchor text for external will cause a penalty. But what about internal links? All of our blog posts include an advertisement linking sales pages. These links all use the exact same anchor text. Is linking to an internal page from so many other pages (blog posts) likely to trigger a penalty? Here is an example: http://www.designquotes.com.au/business-blog/four-ways-to-enhance-your-e-commerce-site-for-busy-shoppers/ This links to http://www.designquotes.com.au/web-design-quotes Many of the posts link to the same page using the anchor text "Compare Web Design Quotes from Local Designers."
Technical SEO | | designquotes0 -
Considering redirecting or canonicalization - Best Practice
Hi, I'm having a techinical problem and I would like advise on the effects this is having on my SEO efforts. My old site www.oldsiteexample.com (live for about 8 years) Directs to my new site www.example.com which is fine BUT When I type me new website into the tool bar both sides are found & do not direct to one domain; www.example.com & example.com (both the same site) What is the best practice here? Direct my new non www to my new www site considering my old website directs to the www. Advise & the SEO affects this is having my website would be greatly appreciated, thank you.
Technical SEO | | Socialdude0