Should I switch from trailing slash to no trailing slash?
-
I have a website which has had trailing slashes added to the URLs by 301 redirects for over 3 years. However, the custom CMS does not allow navigation links to have trailing slashes. This is resulting in 301s every time a user clicks a navigation link.
The site ranks fairy well for some moderately competitive keywords.
If you were in my shoes, would you remove the forced trailing slash redirect in the .htaccess and replace it with a trailing slash removal redirect, or would you leave it like it is?
Thanks,
Jamesp.s. the CMS also doesn't allow canonicals.
-
I'd absolutely agree. If you can get it fixed properly in a couple of months, then leaving the status quo would e better than making interim changes that just trade one set of redirects for another.
P.
-
Hi Paul, that would be the ideal fix. Unfortunately, it won't be an option for at least a couple of months. Maybe best just to wait then.
-
Honestly? I'd spend the time to get the Custom CMS fixed to allow trailing slashes in the navigation links. That would eliminate the redirect issue, Instead of just trading it off to another set of links that would have to redirect.
It sounds like a code sanitising issue in the CMS. Worth spending a couple of hundred dollars to fix the root cause of the issue instead of spending that money to apply bandaids that cause other problems elsewhere. (And bonus, maybe you can get proper canonicalisation built at the same time.)
Of course, yea, this does depend on having/finding a competent developer and having a test environment that doesn't endanger the live site.
Any chance you could push for this option?
Paul
-
Hi James
The reality is that it doesn't matter whether there is a trailing slash or not at the end of your URLs. What is important is that only one version is used and preferably there is no 301 from one to the other if it can be avoided. Especially if there are live links going to one or the other on the front end of your website.
So in your case you have navigation links with no trailing slash and a forced 301 adding them on.
I would remove the htaccess code which is forcing everything to a trailing slash and then add a piece of code removing it from any inbound requests.
Clearly, all backlinks will include the slash including Google - adding the code will resolve these pretty quickly and your existing search results will flick over when they are next crawled. This will depend on the size of your website and the crawl rate. You can check this in webmasters.
Remember that if you do this the backlinks from other websites will have a trailing slash and when the hits come in the new 301 will take them to a non-trailing slash. There may be a small drop in link juice from these backlinks. (I say 'maybe' as Rand Fishkin still believes so - others swear blind there isn't) so be prepared.
You have to balance this small backlink problem with actively pointing to URLs that 301s that redirect. Any SEO will tell you that this is not good! Presumably, the sitemaps don't have trailing slashes? So your site says one thing and your sitemaps another - a nightmare.
This is a version of the code to be placed at the top:
RewriteEngine On
RewriteCond%{REQUEST_FILENAME}!-d
RewriteRule^(.*)/$ /$1 [L,R]# <- for test, for prod use [L,R=301]I hope that helps
Regards
Nigel
-
Hi James,
Really sorry to hear about your problem, this kind of situation can be a real pain in the neck. If I were you, I would look for a better CMS which gives me a freedom to do a better SEO. If you still wish to continue with this CMS, you should map 301 the URLs for trailing slashes to their working locations.
I hope this helps.
Regards,
Vijay
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
-
Does having active urls with and without trailing .html impact SEO?
A recent update resulted in duplication of urls on our site due to inconsistent url structure: Example: /category2.html and /category2 both active on the site as the same page Will this hurt and should we create redirects using only one version of the url? /category2.html redirect to /category2
Intermediate & Advanced SEO | | Karri_Parks0 -
Will switching my domain cause SEO suicide?
Hi, Community! Had a client for many years, MN Plumbing & Appliance Installation: mnplumbingandappliance.com We're re-branding as MN Plumbing & Home Services. We're wanting to change the domain to:mnplumbingandhomeservices.com Problem is, we have some 20+ great backlinks, a DA of 46 (pretty good for us), and a domain age of over 10 years! Will switching this domain cause SEO suicide?
Intermediate & Advanced SEO | | Quistdesigns0 -
Huge Search Traffic Drop After Switching to HTTPS - No Recovery After Couple of Months
Hi In November, we have switched our website (https://www.insidermonkey.com) from HTTP to HTTPS. Initially, we noticed slight search traffic loss but later discovered it might be due to HTTPS switch. A month later we added the https version at search console, and then saw an immediate huge drop (about 25-30%). We discovered the problem might be due to poor redirection and noticed our redirects were 302s instead of 301s. To fix the problem, we implemented the 301 redirects and submitted the sitemap containing links to the old site at the new search console property (https). We've gone through points listed on the page below: https://support.google.com/webmasters/answer/6073543 We fixed the redirects to 301 Double-checked the sitemaps Made sure we had a properly installed SSL certificate (Now, we get A+ from https://www.ssllabs.com/ssltest/analyze.html?d=www.insidermonkey.com) Made sure we have no mixed-content errors (we don't have any issues at search console.) We only avoided implementing HSTS, in case we might want to switch back to HTTP.
Intermediate & Advanced SEO | | etakgoz
We had a small improvement in the following month, but our traffic did not fully recover. We wanted to test for the possibility to switch back HTTP by switching only 2 articles in our CMS to HTTP. Our traffic got worse, not only for those but for the whole site. Then we switched back those 2 articles to HTTPS again and implemented HSTS. It seems our search traffic getting worse day by day with no sign of improving. In the link below you can find the screenshot of our weekly search traffic between 1 October - 1 March. We are down from 500K weekly visitors to mere 167K last week. https://drive.google.com/open?id=1Y1TQbj_YtGG4NhLORbEWbvITUkGKUa0G Any ideas or suggestions? We are willing to get professional help as well. What is the way to find a proper consultant for such problem with relevant experience?0 -
Website Not Performing after switch to HTTPS
We recently switched our client's website to HTTPS but after the move, we've experienced a huge decrease in rankings (off the map), and traffic. Our metas for the homepage are not being picked up by Google, although it was appearing correctly before the switch. We've implemented all redirects, resubmitted URL to Google, and updated GSC. GSC is also reporting errors in our XML stating there are no URLs to crawl. Has anyone had any issues similar? What do you all recommend? Help greatly appreciated
Intermediate & Advanced SEO | | SMRTCHInteractive0 -
Enormous 7 page drop after switching servers and adding load balancers. Thoughts?
Hello Everyone, I'm a longtime Moz user but I had to switch accounts after switching jobs. I was hoping someone might be able to give me some insight on whats going on if possible. Our startup had first page position for our most valuable keyword: "Crowdfunding real estate" for about 6 or 7 months. Once we launched and switched to a production server behind load balancers, we dropped almost overnight to 7th page and we've been there for about a month. We don't have many links yet and some of the ones we DO have are kind of spammy (no idea where they came from and in process of trying to get them removed) but we thought it'd be strange to see that massive drop. We are even pages below a competitor who has NO links and basically zero content on the page. We don't have any notifications in WMT about a manual penalty or anything. I'd really, really appreciate any advice and If anyone has any ideas, the page is at: PatchofLand.com Thanks, Jason
Intermediate & Advanced SEO | | PatchofLand0 -
Trailing slash and rel="canonical"
Our website is in a directory format: http://www.website.com/website.asp Our homepage display URL is http://www.website.com which currently matches our to eliminate the possibility of duplicate content. However, I noticed that in the SERPs, google displays the homepage with a trailing slash http://www.website.com/ My question: should I change the rel="canonical" to have a trailing slash? I noticed one of our competitors uses the trailing slash in their rel="canonical" Do potential benefits outweigh the risks? I can PM further information if necessary. Thanks for the assistance in advance...
Intermediate & Advanced SEO | | BethA0 -
Are there any disadvantages of switching from xml sitemaps to .asp sitemaps in GWT
I have been using multiple xml sitemaps for products for over 6 months and they are indexing well with GMT. I have been having this manually amended when a product becomes obsolete or we no longer stock it. I now have the option to automate the sitemaps from a SQL feed but using .asp sitemaps that I would submit the same way in GWT. I'd like your thoughts on the Pro's and cons of this, pluses for me is realtime updates, con's I percieve GMT to prefer xml files. what do you think?
Intermediate & Advanced SEO | | robertrRSwalters0 -
Would switching domain names be a good move?
Hi All, I'm trying to decide whether to switch to a more relevant domain name for an SEO project. For a while now I've already been doing the standard SEO work on an existing website, content optimization, link building etc but I can't help feeling I won't ever get the full benefits of SEO until I also change the domain name. The current website is for a law firm in new jersey called sandz.net which obviously has no immediate impression it is for a law firm so I'm looking at setting up a new domain and doing 301s to a new site. My concerns are that as its a highly competitive market, I've initiated the campaign to target local searches so I'm wondering just how beneficial buying a domain name with the term lawyer or attorney which actually be. And of course the ideal domain names such as njlawyer, NJattorney .COMs are all taken so I would be looking at perhaps a .ORG with the intention that all printed material the firm has still contains their original name, sandz.net and by word of mouth they should tell people their site is sandz.net as its easy to remember but for the sake of SEO and links then these should all be focused on a new domain.. Any thoughts appreciated.. Thanks
Intermediate & Advanced SEO | | davebrown19750