Http to https redirection issue
-
Hi,
i have a website with http but now i moved to https. when i apply 301 redirection from http to https & check in semrush it shows unable to connect with https & similar other tool shows & when i remove redirection all other tools working fine but my https version doesn't get indexed in google. can anybosy help what could be the issue?
-
Tim Holmes gave a good answer but it does assume your redirects are being applied via a .htaccess file which is the usual method if your website is hosted on a Linux / Apache server.
If your website runs on a Windows / IIS server, then instead of implementing your redirect rules via .htaccess you'd be using web.config instead. Obviously most plugins (especially on common platforms like WordPress) are coded to interact with a .htaccess file. If you're running on IIS instead they could break stuff or at the least fail to function entirely.
On Google you can find many posts complete with web.config instructions:
https://www.google.com/search?num=100&q=https+redirect+for+web.config
This is the one which Google gives the knowledge-graph entry to:
https://www.ssl2buy.com/wiki/http-to-https-redirect-using-htaccess-or-web-config
The second part of the content deals with Windows.
Checking that your SSL certificate is correctly installed, valid and provided by a supplier which Google accepts is highly advisable. If browsing to an HTTPS URL on Chrome yields warnings or 'not secure' messages, it's safe to say that Google has not accepted your SSL certificate. If you can't even browse to HTTPS URLs, something is likely wrong with the install!
Hope that helps
-
Without your URL it is pretty hard to diagnose the issue, it could be multiple problems.
I use the following redirect in my .htaccess file....
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{HTTP_HOST} !^www.domain.co.uk [NC]
RewriteCond %{HTTP_HOST} !^$
RewriteRule ^(.) https://www.domain.co.uk/$1 [L,R,NE]--
I also enable HSTS on my server to perform the same thing and force to run via https://I would also suggest checking that your SSL certificate parts are installed correctly on your server.
Hope that helps a bit.
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
-
301 Redirects Backlinks?
I am wondering how many people still getting results from 301 redirects from high authority expired domains..? I read few case studies on detailed dot com where the shared some people still making big bucks from this strategy which i think 10beast also implemented few years back.? Is it worth it to test out 301 redirects to money sites.? How many people on the moz community here have implemented this strategy in practical and can share some insights and pros and cons of doing 301 redirects? Many Thanks.
Technical SEO | | asifseo0980 -
Using http: shorthand inside canonical tag ("//" instead of "http:") can cause harm?
HI, I am planning to launch a new site, and shortly after to move to HTTPS. to save the need to change over 5,000 canonical tags in pages the webmaster suggested we implement inside the rel canonical "//" instead of the absolute path, would that do any damage or be a problem? oranges-south-dakota" />
Technical SEO | | Kung_fu_Panda0 -
How bad is it to have duplicate content across http:// and https:// versions of the site?
A lot of pages on our website are currently indexed on both their http:// and https:// URLs. I realise that this is a duplicate content problem, but how major an issue is this in practice? Also, am I right in saying that the best solution would be to use rel canonical tags to highlight the https pages as the canonical versions?
Technical SEO | | RG_SEO0 -
Homepage indexation issue
Hello all, I've been scratching my head about this one for a while now... Let me explain the situation. I'm working on a multi-lingual website. Visitors are redirected (301) when they visit the homepage to the correct domain.com/en/default.html, domain.com/nl/default.html, domain.com/fr/default.html or domain.com/de/default.html based on browser language. I have doubts about the impact on the ability for Google to index the website because of that, but that's a problem for another day. The problem I'm having right now, is that domain.com/nl/default.html, domain.com/de/default.html and domain.com/fr/default.html are all indexed. When I search for the URL in Google I get the correct page on number one so I'm pretty sure those are indexed correctly. When I search for domain/en/default.html though, the homepage appears without /en/default.html extension. Does this mean Google assumes the domain.com page is the same as domain.com/en/default.html even though the redirect that's in place? Would be great if someone could shed some light on this. Thanks in advance!
Technical SEO | | buiserik0 -
How should I set up a domain redirect
A client has 2 domains that he wants to use for the same site. At the moment one domain is just an abbreviation of the main domain (not sure why) as follows: www.mygreatpropertycompany.com
Technical SEO | | davidmaxwell
www.mgpc.com (just redirects to the above) He is complaining that when he searches for 'mpc' there are no results (at all) so I'm wondering what the best approach is.There is currently nothing on the main domain that refers to 'mgpc' in it's abbreviated sense - the only place it's being used is the company's email addresses (info@mgpc.com). The redirect is simply a html file in the root of www.mgpc.com as follows: Is there anything I can do to help him out? (this is one of those 'doing a friend a favour' tasks!) Thanks!0 -
Canonicalization Issue?
Good day! I am not sure if my company has a Canonicalization issue? When typing in www.cushingco.com the site redirects to http://www.cushingco.com/index.shtml A visitor can also type in http://cushingco.com/index.shtml into a web browser and land on our homepage (and the url will be http://www.cushingco.com/index.shtml) A majority of websites that link to our company point to: http://www.cushingco.com/index.shtml We are in the process of cleaning up citations and pulling together a content marketing strategy/editorial calendar. I want to be sure folks interested in linking to us have the right url. Please ask me any questions to help narrow down what we might be doing incorrectly. Thanks in advance!! Jon
Technical SEO | | SEOSponge0 -
How long should I keep 301 redirects?
I have modified a the URL structure of a whole section of a website and used mod_rewrite 301 redirect to match the new structure. Now that was around 3 months ago and I was wondering how long should I keep this redirect for? As it is a new website I am quite sure that there are no links around with the old URL structure but still I can see the google bot trying from time to time to access the old URL structure. Shouldn't the google bot learn from this 301 redirect and not go anymore for the old URL?
Technical SEO | | socialtowards0 -
Canonical Issues with Wordpress
Hi all, I have just started using Wordpress SEO by Yoast and still having a hard time correcting my Canonical issues for all posts with a .html at the end. The pluggin allows you to add a '/' to the end for canonical issues, but just for pages, not posts. How best in Wordpress to make my post change from .html/ to .html. I really don't want to go to the hassle to make each URL a new 301 redirect in my .htaccess. I hate the .html, but if they are going to stay, how can I make sure I get the .html/ link juice back to them. Many thanks!
Technical SEO | | RunningInTheRain0