Site-wide Canonical Rewrite Rule for Multiple Currency URL Parameters?
-
Hi Guys,
I am currently working with an eCommerce site which has site-wide duplicate content caused by currency URL parameter variations. Example:
https://www.marcb.com/?setCurrencyId=3
https://www.marcb.com/?setCurrencyId=2
https://www.marcb.com/?setCurrencyId=1
My initial thought is to create a bunch of canonical tags which will pass on link equity to the core URL version. However I was wondering if there was a rule which could be implemented within the .htaccess file that will make the canonical site-wide without being so labour intensive.
I also noticed that these URLs are being indexed in Google, so would it be worth setting a site-wide noindex to these variations also?
Thanks
-
Added to note - you can also use GDC to inform Google which URL parameters should be ignored when indexing - can be a quick shortcut initially, but you'll definitely want to get rel-canonical properly implemented for Google as well as all the other search engines.
-
This issue is resolved by adding a single self-referential rel-canonical tag to the header of each page of the site, Catherine. Once you've done that, the URLs that contain the parameters will automatically contain the canonical to the primary URL (because the pages' code are actually the same - it's just the URL itself that is changing. By which I mean - there aren't separate pages for each of the currencies. They're are all the same page code, with just the parameter added to the URL and prices dynamically changed.)
This does mean that the search engines would index the page with the default prices, which appears to be Euros.
For example, if your home page had a self-referential canonical tag, it's canonical tag would be
<link rel="<a class="attribute-value">canonical</a>" href="<a class="attribute-value">http://www.marcb.com</a>" />
While this may seem redundant, it also means that this URL https://www.marcb.com/?setCurrencyId=2 would also contain the above canonical tag, since the page is actually built from the same code. So it's canonical would point to the correct URL automatically, without having to do anything specific for all those variations. This is a core function of how CMSs (Content Management Systems) templates work. This time it works in your favour.
You definitely don't want to no-index those parameter-based variations even if you could. Once you get the canonicals properly implemented, you want the search crawlers to keep crawling those pages URLs so they can discover the corrected canonicals and understand that they are intentional dupes of the core page. They'll eventually drop the parameter-based URLs out of the index, which you can monitor in your Google Search Console, for example. There's a major benefit to the site if the search crawlers aren't wasting their time on duplicate/useless pages, as well as reducing potential issues with Panda/Quality algorithms, so well worth getting this corrected right away.
Hope all that makes sense?
Paul
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
-
Adding Canonical Tags in WYSIWYG Section of Subscription Based Sites
Our company has a paid subscription-based site that only allows us to add HTML in the WYSIWYG section, not in the backend of each individual page. Because we are an e-commerce site, we have many duplicate page issues. Is there a way for us to add or hide the canonical code in the WYSIWYG section instead of us having to make all of our pages significantly different?
Intermediate & Advanced SEO | | expobranders0 -
Sites in multiple countries using same content question
Hey Moz, I am looking to target international audiences. But I may have duplicate content. For example, I have article 123 on each domain listed below. Will each content rank separately (in US and UK and Canada) because of the domain? The idea is to rank well in several different countries. But should I never have an article duplicated? Should we start from ground up creating articles per country? Some articles may apply to both! I guess this whole duplicate content thing is quite confusing to me. I understand that I can submit to GWT and do geographic location and add rel=alternate tag but will that allow all of them to rank separately? www.example.com www.example.co.uk www.example.ca Please help and thanks so much! Cole
Intermediate & Advanced SEO | | ColeLusby0 -
Is it Wortwhile to have a HTML site map for a Large Site
We are a large, enterprise site with many pages (some on our CMS and some old pages that exist outside our CMS). Every month we submit various an XML site map. Some pages on our site can no longer be found via following links from one page to another (orphan pages). Some of those pages are important and some not. Is it worth our while to create a HTML site map? Does any one have any recent stats or blog posts to share, showing how a HTML site map may have benefited a large site. Many thanks
Intermediate & Advanced SEO | | CeeC-Blogger0 -
Add URL parameters in SEOMoz as per GWT?
Hi, this may be a tall order, or maybe it's already in place and I'm behind the times! Any chance on getting something like this going? Even handier, have SEOMoz import these settings directly from GWT. The issue comes into play when looking at my duplicate page content reports; I'm guessing that SEOMoz will continue showing these as duplicates even after I have tweaked GWT to read them properly. Haven't tested this theory as I just started down this road on GWT myself. Thanks. 🙂
Intermediate & Advanced SEO | | ntcma0 -
Lost all ranking after site-wide 301 redirect
Hi all I did a complete site-wide 310 redirect about 3 weeks ago for a site that had consistently been in Pos 1-5 for my targeted keyword ("low glycemic foods"). I changed the domain from low-glycemic-foods-org to low-glycemic-diet.com because I thought that was a more appropriate title and thru my readings I believed that if I carefully followed the recommended procedures I would quickly regain my SERP. Webmaster tools is showing that I have over 800 inbound links - many from very trustworthy sources including .edu, etc BUT my home page is nowhere to be found for the keyword search "low glycemic diet". My Seomoz onpage SEO score is an "A" Any enlightenment would be much appreciated.
Intermediate & Advanced SEO | | veezer0 -
Dynamic URLs Appearing on Google Page 1\. Convert to Static URLs or not?
Hi, I have a client who uses dynamic URLs thoughout his site. For SEO purposes, I've advised him to convert dynamic URLs to static URLs whenever possible. However, the client has a few dynamic URLs that are appearing on Google Page 1 for strategically valuable keywords. For these URLs, is it still worth it to 301 them to static URLs? In this case, what are the potential benefits and/or pitfalls?
Intermediate & Advanced SEO | | mindflash0 -
URL structure + process for a large travel site
Hello, I am looking at the URL structure for a travel site that will want to optimise lots of locations to a wide variety of terms, so for example hotels in london
Intermediate & Advanced SEO | | onefinestay
hotels in kensington (which is in london)
five star hotels in kensington
etc I am keen to see if my thought process is correct as you see so many different URL techniques out there. Or am i overthinking it too much? Lets assume we make the page /london/ as our homepage. we would then logically link to /london/hotels to optimise specifically for 'london hotels' We then have two options in my mind for optimising for 'kensington hotels': Link to a page that keeps /london/hotels/ in its URL to maintain consistency ie A. /london/hotels/kensington or should we be linking to: B. /london/kensington/hotels/ (as it allows us to maintain a logical geo-landing page hierarchy) I feel A is good as the URL matches the search phrase 'hotels in kensington' matches the order of the search phrase, but it loses value if any links find these pages with 'kensington' in the anchor text, as they would not really strengthen the 'kensington' hub page. /london/kensington Ie: i land on the 'kensington hotels' page and want to see more about kensington, then i could go from /london/kensington/hotels
to
/london/kensington quite easily and logically in the breadcrumb. I feel B. is the best option for now.. Happy to I am only musing as i see some good sites that use option A, which effectively pushes the location (/kensington/ to the end of the URL for each additional niche sub page, ie /london/hotels/five-star-hotels/kensington/) Some of the bigger travel sites dont even use folder, they just go:
example.com/five-star-hotels-in-kensington/ Comments welcome!!! Thanks0 -
WWW vs Non-WWW/Moving a site to a new CMS/Redirect all of the previous URLs
We are working on a new design for a website, which is currently on a CMS that has non-seo-friendly URLs. There is no redirection of 'www' to non-www or vice versa, or handling of homepage redirection so there is only one instance of 'home'. To move the site in the future, all of these URLs will have to be redirected to their new, and I hope, seo-friendly counterparts. Is it prudent now to redirect the four home page links so there is only one? and to redirect all non-www to 'www' so there is only one instance of each page? Or should I leave it and redirect all of them when the time comes?
Intermediate & Advanced SEO | | haan_seo0