HTTPS 301 Redirect Question
-
Hi,
I've just migrated our previous site (siteA) to our new url (siteB) and I've setup 301 redirects from the old url (siteA) to the new (siteB). However, the old url operated on https and users who try to go to the old url with https (https://siteA.com) receive a message that the server cannot be reached, while the users who go to http://siteA.com are redirected to siteB.
Is there a way to 301 redirect https traffic?
Also, from an SEO perspective if the site and all the references on Google search are https://siteA.com does a 301 redirect of http pass the domain authority, etc. or is https required?
Thanks.
-
Hi Jonathon,
Below is what I have in my htaccess file:
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] -
I don't know if you admin your own server, but if you do, you should be able to easily tell it to redirect HTTP to HTTPS. I do this with Apache (it's much easier and faster than .htaccess) and it works really well.
-
Hi Jonathon,
If the one I posted above doesn't work, try this one:
Options +FollowSymLinks
RewriteEngine On
RewriteRule ^(.*) https://www.newsite.com%{REQUEST_URI} [R=301,NC]Both should do exactly what you want, but let me know how you go!
Cheers,
David
-
Hi David,
Thanks.
the htaccess for the site currently looks like this:
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.oldsite.com$ [NC]
RewriteRule ^ https://www.newsite.com%{REQUEST_URI} [R=301,L]
The end goal would be to redirect:
To the new url:
Thanks for your help.
-
Hi Jonathon,
I did this recently and used the following in my htaccess file:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^oldsite.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.oldsite.com$
RewriteRule (.*)$ https://www.newsite.com/$1 [R=301,L]It redirects http and https to the new domain.
Is this what yours looks like? Can you copy and paste what you are using in your htaccess file so we can check it out? (use oldsite/newsite - don't need to give us the domain)
Cheers,
David
-
Hi,
Sorry I may not have explained the issue well enough.
I'm still looking to use https.
I simply want to redirect https://oldsite.com (and http://oldsite.com) to https://newsite.com, but I can seemingly only redirect http traffic with a 301 redirect in the htaccess file.
Thanks.
-
Google recommends using https (https://webmasters.googleblog.com/2014/08/https-as-ranking-signal.html). Is there a reason why you no longer wish to utilize it?
Otherwise, this might work for your redirect: http://stackoverflow.com/questions/8371/how-do-you-redirect-https-to-http
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
-
How long does Google take to completely authorise 301 redirect?
Will 301 redirect will have immediate impact once the website or that redirected link got indexed? We have recently redirected few links in the process of link reclamation and ranking dropped few days later. Every link we claimed is related to our topic (matched in content and URL) and they have good DA. Even though why it has happened? What are the general rank dropping factors in the process of link reclamation? Thanks, Satish
Intermediate & Advanced SEO | | vtmoz0 -
301 or Canonical - Ecommerce Site Question
We are making a change to our Navigation and this includes having to change the URL structure of a few pages of our site. Due to issues with the CMS (that are out of my control) we are unable to keep the current URL structure of two of our highest ranking pages. Our site is an E-commerce Site The Structure is changing from..... www.domain.com/page/highrankingpage <----OLD PAGE RANKED WELL to www.domain.com/category/highrankingpage <----NEW PAGE Generally I would have 301 'd this page but I found out that our Tech team added a Canonical to this page instead....(showing the high ranking page to the Search Engines) and on our site the visitors are able to browse the website getting the new page. BOTH PAGES ARE BASICALLY IDENTICAL (Same Content) http://searchenginewatch.com/sew/how-to/2288690/how-and-when-to-use-301-redirects-vs-canonical# Thoughts?
Intermediate & Advanced SEO | | CMcMullen0 -
301 redirects in Wordpress vs. making old posts that you no longer want your audience to see private.
I'm working on Wordpress at the moment changing the content of a page on my website. The page has a lot of educational information and each section is unique. I had to go through and edit each section on google documents and now I'm posting all the new pages and making the old pages private on wordpress. Is this a good idea? I'm worried google will still crawl my private education pages and think these are duplicates since the new pages somewhat resemble the old. Also, should I be 301 redirecting all the old education pages to the corresponding new ones even if they are private on wordpress? I understand that the 301 redirect should only be used if you want the old page to go to a new one. What i don't understand id weather this will still be relevant or work if I've already made the old page private on wordpress. Thank You!
Intermediate & Advanced SEO | | SapphireCo0 -
Duplicate content reported on WMT for 301 redirected content
We had to 301 redirect a large number of URL's. Not Google WMT is telling me that we are having tons of duplicate page titles. When I looked into the specific URL's I realized that Google is listing an old URL's and the 301 redirected new URL as the source of the duplicate content. I confirmed the 301 redirect by using a server header tool to check the correct implementation of the 301 redirect from the old to the new URL. Question: Why is Google Webmaster Tool reporting duplicated content for these pages?
Intermediate & Advanced SEO | | SEOAccount320 -
Confusing 301 / Canonical Redirect Issue - Wizard Needed
I had two pages on my site with identical content. What I did was 301 redirect one page to the other. I also added canonical redirect code to the page that held the 301 code. Here is what I have: www.careersinmusic.com/music-colleges.aspx - this page was a duplicate and I needed it to resolve to:
Intermediate & Advanced SEO | | 4Buck
www.careersinmusic.com/music-schools.aspx Here is the code I used: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX music-colleges.aspx
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="music-colleges.aspx.vb" Inherits="music_colleges" %>
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
http://www.w3.org/1999/xhtml"> http://www.careersinmusic.com/music-schools.aspx"/> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
music-colleges.aspx.vb
Partial Class music_colleges
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Response.Status = "301 Moved Permanently"
Response.AddHeader("Location", "http://www.careersinmusic.com/music-schools.aspx")
End Sub
End Class XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX The problem:
For some reason, when the search “music colleges” is done in Google, I am #7. When the term “music schools” is done, I am around 119. I MUST be getting a penalty for some reason, I just cannot figure the reason. When perform well for one term and terrible for the next? All I can come up with is a duplicate content penalty or something along those lines. Also, music-colleges.aspx seems to still be in Googles index, even though the above 301 happened months ago. Thoughts? site:www.careersinmusic.com/music-colleges.aspx Any insight into this would be GREATLY appreciated. Many Thanks!0 -
New to SEO. How do I set up a 301 Redirect? What Else should I do?
Hello, I am new to web design. I designed my own site using dreamweaver and did all my seo on my own, I read a few books. Long story short I rank on the bottom of page 1 just after 3 months and the keywords are highly competitive. Now, I am up against some heavy hitters from national brands versus my local real estate site. I don't have a 301 redirect, and am not sure what else I should be doing to get my site ranked higher. I have back links from various sites, ( non-paid ) so it's what others call white hat. When I grade my site on website grader I get a great score versus the sites that are higher than me. I'm guessing my sites age is an issue. I guess I'm looking for some guidance. Thank you all, Here is my site to view. http://www.bronxpad.com
Intermediate & Advanced SEO | | bronxpad0 -
301 redirect for duplicate content
Hey, I have just started working on a site which is a video based city guide, with promotional videos for restaurants, bars, activities,etc. The first thing that I have noticed is that every video on the site has two possible urls:- http://www.domain.com/venue.php?url=rosemarino
Intermediate & Advanced SEO | | AdeLewis
http://www.domain.com/venue/rosemarino I know that I can write a .htaccess line to redirect one to the other:- redirect 301 /venue.php?url=rosemarino http://www.domain.com/venue/rosemarino but this would involve creating a .htaccess line for every video on the site and new videos that get added may get missed. Does anyone know a way of creating a rule to rewrite these urls? Any help would be most gratefully received. Thanks. Ade.0 -
301 Redirect - How Long Until Recovery?
How long after one moves a page and sets up the 301s should the site take to regain its previous rankings? Context: i've ported a site to a new framework. Along the way, several high ranked pages needed to have new URLs setup, as well as the site moved from www.domain.com to simply domain.com. About 1 week after the change, the site's traffic went down 70% and has been there for about another 2 weeks. I suppose it could be something about the new framework that is causing problems though according to SEOMoz tools, the new framework is checking out pretty well. I assume the problem is reconciling all those old www inbound links with the new non-www location. It is all 301'd however ... so it should be working, but is not. So my questions are: 1. How long should it take Google to reconcile these changes and put us back to original SERP positions 2. is there something inherently problematic with switching from www to non-www?
Intermediate & Advanced SEO | | NealCabage0