Magento Trailing Slash URL Problem
-
Howdy Mozzers!
Our magento store URL's are accessible with or without a trailing slash at the end. Canonical's and 301 redirects are not set up for one of them at the moment.
Will this cause duplicate issue? Do we need to set canonical or 301 up? Which one is recommended?
MozAddict
-
Ok, so we could canonical the first page in the pagination, that way any links to the pagination would flow juicy juice to the first page. That would make sense, since it would strengthen its ranking as a landing page as well.
I think ill implement the canonical and get rid of the content on pagination anyways, just avoid the problem completely.
Ace Marty!
-
If you are using rel canonical then you can have the same on each page and it should be okay.
Otherwise, I would make sure your paginated pages don't have it. The next/prev helps Google to understand these are subsequent pages of the original category but it doesn't really give instruction as to the preferred page, etc. (like the canonical would) so you could end up with Google ignoring the content after it sees it too many times.
-
Appreciate your response Marty.
What is your opinion on content for category pages. Currently we have the same content displaying on paginated pages for the same category (?p=1, ?p=2, etc)
Should we display content just on the first page and remove it for rest of the pagination or is this ok?
We are using rel="next/prev" but not sure if this is treated as duplication?
-
I personally prefer the slash but it doesn't make any difference as long as you're consistent and if as you say Google is already indexing most without, I'd probably go that way too!
-
Great answers guys! I would personally also prefer 301's over canonicals. So the next questions is, to keep URLs with the trailing slash or without the trailing slash. I tend to lean towards without, since most URL's are indexed that way already, its easier on the eyes, and people tend to link that way.
Any preference?
-
Good day MozAddict!
SEO for Magento is near and dear to my heart. From a technical SEO perspective, I would recommend cleaning up the items you mentioned as it can cause issues. The biggest concern is trust flow and having trust split between two versions of the page (ie: the slash and no-slash).
So both the 301 and canonical tag will pass the same amount of trust as the other. So your question is, which do you go with? I think both are fine however I prefer the 301 myself for dealing with the trailing slash issue and here's why.
As time passes, believe it or not, people will link to some of your pages naturally. Because a canonical or 301 doesn't pass the full trust earned from the link, I'd rather someone link to the correct version. If I'm using the canonical tag, they may indeed link to the non-preferred version and I would lose some of that trust, whereas if I am using the 301, they will automatically be shown the correct, preferred version and I earn all the trust from that natural link.
Moz has a great article on canonicalization if you want to read more on it.
Hope this answer is useful to you!
-
Definitely a duplication issue as they are 2 different pages. Pick one way and stick to it, probably remove is the easiest. I would do redirects first, but set canonical as well as a best practice. There is a great guide here:
http://www.kodecreations.co.uk/google/remove-trailing-slash-magento-urls-duplicate-content-issue/
It even includes instructions on how to stop Magento from generating urls with trailing slashes.
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
-
Should you shorten very long URLs?
Hi Moz Community! If the nav architecture URL is long, like this: https://www.savewildlife.org/wildlife-conservtion/endangered-species-act-protections/endangered-species-list/birds/mexican-spotted-owl can I and should I shorten that new destination URL to make it easy for Google to see that the page topic is really the owl, like this: https://savewildlife.org/endangered-species-list/mexican-spotted-owl Thank you! Jane
Intermediate & Advanced SEO | | CalamityJane771 -
Changing URLs
URLs of my web pages are based on the titles of pages. For sampel, if a title page is called "product ABC", then the URL for this page is /product-abc. Google and all other search engines have indexed all pages. Now I want to change the titles of some sites. Should I change the URLs accordingly, or should I rather leave URLs as they are. SEO Best Practice says that keywords must be placed both in the title, and in the URL. I think that Google will think that pages have douplicate content with diffrent titles, and it comes to many 404 error, if I change the URLs. What do you recommend in this case?
Intermediate & Advanced SEO | | kian_moz0 -
What would cause these ⠃︲蝞韤諫䴴SPপ� emblems in my urls?
In Search Console I am getting errors under other. It is showing urls that have this format- https://www.site.com/Item/654321~SURE⠃︲蝞韤諫䴴SPপ�.htm When clicked it shows 蝞韤諫䴴SPপ� instead of the % stuff. As you can see this is an item page and the normal item page pulls up fine with no issues. This doesn't show it is linked from anywhere. Why would google pull this url? It doesn't exist on the site anywhere. It is a custom asp.net site. This started happening in mid May but we didn't make any changes then.
Intermediate & Advanced SEO | | EcommerceSite0 -
How do I get rel='canonical' to eliminate the trailing slash on my home page??
I have been searching high and low. Please help if you can, and thank you if you spend the time reading this. I think this issue may be affecting most pages. SUMMARY: I want to eliminate the trailing slash that is appended to my website. SPECIFIC ISSUE: I want www.threewaystoharems.com to showing up to users and search engines without the trailing slash but try as I might it shows up like www.threewaystoharems.com/ which is the canonical link. WHY? and I'm concerned my back-links to the link without the trailing slash will not be recognized but most people are going to backlink me without a trailing slash. I don't want to loose linkjuice from the people and the search engines not being in consensus about what my page address is. THINGS I"VE TRIED: (1) I've gone in my wordpress settings under permalinks and tried to specify no trailing slash. I can do this here but not for the home page. (2) I've tried using the SEO by yoast to set the canonical page. This would work if I had a static front page, but my front page is of blog posts and so there is no advanced page settings to set the canonical tag. (3) I'd like to just find the source code of the home page, but because it is CSS, I don't know where to find the reference. I have gone into the css files of my wordpress theme looking in header and index and everywhere else looking for a specification of what the canonical page is. I am not able to find it. I'm thinking it is actually specified in the .htaccess file. (4) Went into cpanel file manager looking for files that contain Canonical. I only found a file called canonical.php . the only thing that seemed like it was worth changing was changing line 139 from $redirect_url = home_url('/'); to $redirect_url = home_url(''); nothing happened. I'm thinking it is actually specified in the .htaccess file. (5) I have gone through the .htaccess file and put thes 4 lines at the top (didn't redirect or create the proper canonical link) and then at the bottom of the file (also didn't redirect or create the proper canonical link) : RewriteEngine on
Intermediate & Advanced SEO | | Dillman
RewriteCond %{HTTP_HOST} ^([a-z.]+)?threewaystoharems.com$ [NC]
RewriteCond %{HTTP_HOST} !^www. [NC]
RewriteRule .? http://www.%1threewaystoharems.com%{REQUEST_URI} [R=301,L] Please help friends.0 -
Short Url vs Medium Urls ?
Hello Moooooooooooz ! I got a SEO fight today and though the best would be to involve more people into the fight ! 😛 Do you think it's better to get A- company.com/services/service1.html or B- company/service1.html I was for A as services is also googled to find the service1. I also think that it's better to help google to understand where the service is on the website My friend was for B as URL has to stay as short as possible What do you think ? ps: I can create the URL I want using Joomla and Sh404. The websites has 4 different categoies: /about, /services/ products, /projects Tks ! 🙂
Intermediate & Advanced SEO | | AymanH0 -
Should /node/ URLs be 301 redirect to Clean URLs
Hi All! We are in the process of migrating to Drupal and I know that I want to block any instance of /node/ URLs with my robots.txt file to prevent search engines from indexing them. My question is, should we set 301 redirects on the /node/ versions of the URLs to redirect to their corresponding "clean" URL, or should the robots.txt blocking and canonical link element be enough? My gut tells me to ask for the 301 redirects, but I just want to hear additional opinions. Thank you! MS
Intermediate & Advanced SEO | | MargaritaS0 -
URL for offline purposes
Hi there, We are going to be promoting one of our products offline, however I do not want to use the original URL for this product page as it's long for the user to type in, so I thought it would be best practice in using a URL that would be short, easier for the consumer to remember. My plan: Replicate the product page and put it on this new short URL, however this would mean I have a duplicate content issue, would It be best practice to use a canonical on the new short URL pointing to the original URL? or use a 301? Thanks for any help
Intermediate & Advanced SEO | | Paul780 -
Canonical Problems
Hi Guys, There is so much info out there about canonical issues and 301 redirects I'm not sure what to do about my problem. Google webmaster says I have over 2000 duplicate page titles. Google is showing most of my pages in duplicate or triplicate url format. Example: /store/LOVE_OIL_CARIBBEAN_ROSE//store/LOVE_OIL_CARIBBEAN_ROSE/store/love_oil_caribbean_rose/Im using x-cart pro as my cart.When I look at the source code I see each one having a rel=canonical tag with the exact urls you see above. Can someone give me an example of a redirect that I can put in my .htaccess file that would work site wide?I obviously cant go through and 301 this on a page by page basis. It would take a year.Thank You Tim
Intermediate & Advanced SEO | | fasctimseo0