We are redirecting http and non www versions of our website. Should all versions http (non www version and www version) and https (non www version) should just have 1 redirect to the https www version?
-
We are redirecting http and non www versions of our website. Should all versions http (non www version and www version) and https (non www version) should just have 1 redirect to the https www version?
Thant way all forms of the website are pointing to one version?
-
I am happy I could be of help please let me know if there's anything else I can be of assistance with?
-
PS I will run a crawl to check
-
It is fine to 301 redirect to** "/"** you need to pick forward slash "/" or no forward slash.
- SEE:
- https://webmasters.googleblog.com/2010/04/to-slash-or-not-to-slash.html
- https://www.seroundtable.com/google-trailing-slashes-url-24943.html
You should force HTTPS
- http://cardiff.co.uk 301's to http://www.cardiff.co.uk/
- See: https://i.imgur.com/fg34sXR.png
- You should add https
- https://dash.cloudflare.com/sign-up
- or
- https://www.rapidtables.com/web/tools/redirect-generator.html
Add a SSL cert I would just add cloudflare.com (if you want fast & easy also Free)
- https://support.cloudflare.com/hc/en-us/articles/204144518
- https://support.cloudflare.com/hc/en-us/articles/200172286-Configuring-URL-forwarding-or-redirects-with-Cloudflare-Page-Rules
When configuring Page Rules, the Always use HTTPS action is the simplest method to redirect HTTP requests to HTTPS. You can also use the Forwarding URL action with a 301 redirect if you need to redirect to another subdomain in addition to forcing HTTPS. For example, a Page Rule match for
**_http://_cardiff.co.uk_/*_**
with a _Forwarding URL _of
**_https://www.cardiff.co.uk/$1_**
or ASP.NET
<%@ Language="VBScript" %>
<%
' ASP permanent URL redirect - generated by www.rapidtables.com
Response.Status="301 Moved Permanently"
Response.AddHeader "Location", "https://www.cardiff.co.uk/"
Response.End
%>Redirect entire domain from HTTP to HTTPS
RewriteEngine On RewriteCond %{HTTPS} off RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Redirect entire domain from non-www to www and HTTP to HTTPS
RewriteEngine On RewriteCond %{HTTP_HOST} !^www\. [NC] RewriteRule ^ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301] RewriteCond %{HTTP:X-Forwarded-Proto} !https RewriteCond %{HTTPS} off RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Hope this helps,
Tom
-
Thank you for the advice it is very useful.
In GWT we are also showing redirects on all pages from the non / page to the / page
ie cardiff.co.uk redirects to cardiff.co.uk/
is this OK?
-
if you talking about the domain
you should 301 redirect each of the 3 of 4 different URLs to the one you want to be the primary domain that is using https
This is a great guide
https://ahrefs.com/blog/301-redirects/
You can always use CloudFlare as free & easy fix.
If you want to use HSTS preload or just HSTS
Test your 301 setup using
https://hstspreload.org/?domain=example.com
If you are using https://www. as the primary
See you must force http to https and the HTTP://www
Must redirect to the https:// bare domain so that means two redirects.
Error: No redirect from HTTP
http://example.com
does not redirect tohttps://example.com
.Hope this helps,
Tom
-
Ideally, yes.
However, it's not likely to have a massive impact if you do have a redirect chain first to www and then to https.
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
-
Moving site from www to non www and also hosting to vps what will be the effect?
Hi SEO gurus,
Intermediate & Advanced SEO | | SeoBlogs61
I am trying to move my site from shared hosting to VPS hosting and also moving from www to non www version.
What is the best possible way to avoid any issue and without losing the backlinks.
Is it good or bad to do? URL: https://buylikesservices.com/0 -
301 Redirects - 4 sites into 1
Hey all, I have an SEO conundrum that seems to have no right or wrong answer. If you have 2 minutes I’d love to hear your opinion. The Situation
Intermediate & Advanced SEO | | PamelaH88
Our client has 4 ecommerce sites (Sites A, B, C & D) all selling the same products.
He wishes to to merge all 4 sites into a single site (Site A) Options
In order to maintain maximum SEO authority do we: A - Choose a single site (B, C, or D) with the most SEO authority/juice/power and 301 re-direct it into Site A
Or
B – 301 re-direct all 3 sites (B, C & D) into Site A Our experience says that 301’ing from a single site works well, but from multiple sites feels spammy and risky. Really keen too hear your thoughts.1 -
Can I have multiple 301's when switching to https version
Hello, our programmer recently updated our http version website to https. Does it matter if we have TWO 301 redirects? Here is an example: http://www.colocationamerica.com/dedicated_servers/linux-dedicated.htm 301 https://www.colocationamerica.com/dedicated_servers/linux-dedicated.htm 301 https://www.colocationamerica.com/linux-dedicated-server We're getting pulled in two different directions. I read https://moz.com/blog/301-redirection-rules-for-seo and don't know if 2 301's suffice. Please let me know. Greatly appreciated!
Intermediate & Advanced SEO | | Shawn1240 -
How correcttly redirect to http://m.mobile.com website
Hi everyone, I will appreciate if you will drop here a piece of script ( or link to ) for CORRECT redirection for our http://m.mobile.com website. We are confused what type of redirection should we use java script, htaccess, php, 301, 302....? in order not to damage any rankings and etc... Thanks
Intermediate & Advanced SEO | | Webdeal
webdeal0 -
Redirecting non www site
Hello Ladies and Gentlemen. I 100% agree with the redirecting of the non www domain name. After all we see so many times, especially in MOZ how the two different domains contain different links, different DA and of course different PA. So I have posed the question to our IT company, "How would we go about redirecting our non www domain to the www version?", "Where would we do that?", " we cant do the redirect on our webserver because the website is listed as an IP address, not a domain name, so would we do the redirect somewhere at GoDaddy?" who is currently maintain our DNS record So here is the response from IT: " I would setup a CNAME record in DNS (GoDaddy), such that no matter if you go to the bare domain, or the www, you end up in the same place. As for SEO, having a 301 redirect for your bare domain isn't necessary, because both the bare domain and the www are the same domain. 301 is a redirect for "permanently moved" and is common when you change domain names. Using the bare domain or the www are NOT DIFFERENT DOMAINS, so the 301 would not be accurate, and you'd be telling engines you've moved, when you haven't - which may negatively impact your rank. It sounds to me that IT is NOT recommending the redirect. How can this be? Or are we talking about two different things? Will the redirect cause the melt down as the IT company suggests? Or do they nut understand SEO?
Intermediate & Advanced SEO | | Davenport-Tractor0 -
Redirecting a redirect - thoughts?
Hi! A client has just had 14k 404s pop up in his WMT. I think this is because a page that they redirected to had moved. My question is, can I clean these up by redirecting the page the original redirect was one? If so, will it have any negative impact?
Intermediate & Advanced SEO | | neooptic0 -
301 redirects
Hello, I want to ditch about 1000 pages of a 2000+ page site. I believe the 301 redirect thing is the way to go but my expertise is limited. Is there a way to do a blanket redirect ie if a user or search engine looks for a page thats not there it all gets redirected to the index page or do I have to do each one manually? Thanks Ian
Intermediate & Advanced SEO | | jwdl0 -
301 Redirect All Url's - WWW -> HTTP
Hi guys, This is part 2 of a question I asked before which got partially answered; I clicked question answered before I realized it only fixed part of the problem so I think I have to post a new question now. I have an apache server I believe on Host Gator. What I want to do is redirect every URL to it's corresponding alternative (www redirects to http). So for example if someone typed in www.mysite.com/page1 it would take them to http://mysite.com/page1 Here is a code that has made all of my site's links go from WWW to HTTP which is great, but the problem is still if you try to access the WWW version by typing it, it still works and I need it to redirect. It's important because Google has been indexing SOME of the URL's as http and some as WWW and my site was just HTTP for a long time until I made the mistake of switching it now I'm having a problem with duplicate content and such. Updated it in Webmaster Tools but I need to do this regardless for other SE's. Thanks a ton! RewriteEngine On RewriteBase / RewriteCond %{HTTP_HOST} ^www.yourdomain.com [NC] RewriteRule ^(.*)$ http://yourdomain.com/$1 [L,R=301]
Intermediate & Advanced SEO | | DustinX0