The correct way to rel=canonical
-
When adding the rel=canonical tag to a landing page inside a folder, should the tag read:
or
With or without the index.php?
TY
KJr
-
Thanks Gaston, I've heard it both ways
-
Hello Kevin,
It´s common to recommend avoiding the usage of /index.php.
My suggestion is to go with:
For further reading:
SEO Best Practices for Canonical URLs + the Rel=Canonical Tag - Whiteboard Friday
Consolidate duplicate URLs - Google Search Console HelpHope it helps.
Best luck.
GR.
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
-
How can i fix the canonical tag issue?
I was experiencing today morning some issue on our website page. While I inspected the URL to Google for the page https://www.socprollect-mea.com/dubai-free-zone-company-formation/ I noted the issue. The canonical tag is showing errors only the source code showsThis is a serious issue right?Does anyone have the idea to solve this concern? Please help me to sort it out the issue and guide me on how to fix this WordPress issue.
On-Page Optimization | | nazfazy0 -
Canonicals
I dynamically generated pages using rewrite functions in wordpress (new-york, san-diego, san-francisco). All these pages look the same but with different content. yoast (seo wordpress plugin) was unaware of this and set canonicals up relating to the wordpress page used as the template page for the dynamic pages (City_home_page). so all these pages had the canonical https://dinnerdancecruises.com/City_Home_Page. using search console, i saw google indexed my site, looked at all these dynamically created pages (which is about 30 pages) and took them all in as duplicate pages. this happen sometime in april or may. I fixed this problem and set unique canonicals up for each dynamically created page. but now google is not crawling them for some reason. im not sure why its been months and these pages are not indexed. i thought to myself is it because these links end up on multiple pages? sort of like having "terms of agreement" link at the footer. every single page has that terms of agreement link. does google look at those links as duplicates and not index the page at all. this is where my issue lies. i need google to crawl regularly and see those pages with their new, unique canonicals and re-index them correctly. but it seems to save cpu resources, google feels once a thief always a thief. i could be wrong but this is why i need your suggestion. thank you.
On-Page Optimization | | bobperez7360950 -
Duplicate ecommerce domains and canonical
Hi everybody! I'd like to discuss the SEO strategy I've thought regarding a client of mine and ask for help because it's a serious case of duplicate content. There is a main website (the business model one) where he compares the cost of medicines in several pharmacies, to show the cheapest shopping cart to the customer. But the shopping has to been made in another domain, within the selected pharmacie, because my country's law in Europe says that is compulsory to sell the medicines only on the pharmacy website. So my client has started to create domains, one for each pharmacy, where the differences between them are only some products, the business information of the pharmacy and the template's colour. But all of them shares the same product data base. My aim is to rank the comparing website (it contains all the products), not each pharmacy, so I've started to create different content for this one. Should I place rel=canonical in the pharmacies domains t the original one? For instance: www.pharmacie1.com >> www.originaltorank.com www.pharmacie2.com >> www.originaltorank.com www.pharmacie1.com/product-10 >> www.originaltorank.com/product-10 I've already discuss the possibilities to focus all the content in only one website, but it's compulsory to have different domains in order to sell medicines By the way, I can't redirect 301 because I need these websites exist for the same reason (the law) He is creating 1-3 new domains every week so obviously he has had a drop in his SEO traffic that I have to solve this fast. Do you think the canonical will be the best solution? I dont want to noindex these domains beacuse we're creating Google Local pages for each one in order to be found in their villages. Please, I'll appreciate any piece of advice. Thanks!
On-Page Optimization | | Estherpuntu0 -
Canonical Question For Different Languages
My client has a site that supports different languages in the following structure: www.domain.com - English version www.domain.com/IT - Italian version www.domain/DE - German version etc.... I have set the languages up within Webmaster Tools but do I need to set up the canonical tag for all internal pages as they are basically the same but just in a different language i.e. www.domain.com/index.php is the same as www.domain.com/DE/index.php but in a different language. Thanks
On-Page Optimization | | bigfootdigital0 -
Is reported duplication on the pages or their canonical pages?
There are several sections getting flagged for duplication on one of our sites: http://mysite.com/section-1/?something=X&confirmed=true
On-Page Optimization | | Safelincs
http://mysite.com/section-2/?something=X&confirmed=true
http://mysite.com/section-3/?something=X&confirmed=true Each of the above are showing as having duplicates of the other sections. Indeed, these pages are exactly the same (it's just an SMS confirmation page you enter your code in), however, they all have canonical links back to the section (without the query string), i.e. section-1, section-2 and section-3 respectively. These three sections have unique content and aren't flagged up for duplications themselves, so my questions are: Are the pages with the query strings the duplicates, and if so why are the canonical links being ignored? or Are the canonical pages without the query strings the duplicates, and if so why don't they appear as URLs in their own right in the duplicate content report? I am guessing it's the former, but I can't figure out why it would ignore the canonical links. Any ideas? Thanks0 -
Canonical Notice
I am curious why I receive this canonical notice even though there is a canonical for this homepage. Nq3fD.jpg
On-Page Optimization | | paumer800 -
Rel="canonical" on home page?
I'm using wordpress and the all in one seo pack with the canonical option checked. As I understand it the rel="canonical" tag should be added to pages that are duplicate or similar to tell google that another page (one without the rel="canonical" tag) is the correct one as the url in the tag is pointing google towards it. Why then does the all in one seo pack add rel="canonical" to every page on my site including the home page? Isn't that confusing for google?
On-Page Optimization | | SamCUK0 -
Optimise duplicate products or canonical link
We exist in a niche market with a good % of products that sell well at specific times of the year. Lets say for example a red cup can be sold as a christmas red cup and a valentine red cup or just a red cup. Would we be best to optimize each specific product specifically for those seasons/events on different pages or keep google pointed to just one page using a canonical link.
On-Page Optimization | | LadyApollo0