The Moz Q&A Forum

    • Forum
    • Questions
    • My Q&A
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

    Browse the forum for helpful insights and fresh discussions about all things SEO.

    1. SEO and Digital Marketing Q&A Forum
    2. Categories
    3. Intermediate & Advanced SEO
    4. HTTPS 301 Redirect Question

    HTTPS 301 Redirect Question

    Intermediate & Advanced SEO
    8 4 105
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • opstart
      opstart last edited by

      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.

      1 Reply Last reply Reply Quote 0
      • Brando16
        Brando16 last edited by

        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

        1 Reply Last reply Reply Quote 0
        • opstart
          opstart last edited by

          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.

          1 Reply Last reply Reply Quote 0
          • davebuts
            davebuts last edited by

            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

            1 Reply Last reply Reply Quote 0
            • opstart
              opstart last edited by

              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:

              http://oldsite.com

              http://www.oldsite.com

              https://oldsite.com

              https://www.oldsite.com

              To the new url:

              https://www.newsite.com

              Thanks for your help.

              1 Reply Last reply Reply Quote 0
              • davebuts
                davebuts last edited by

                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

                1 Reply Last reply Reply Quote 0
                • Highland
                  Highland last edited by

                  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.

                  1 Reply Last reply Reply Quote 0
                  • Brando16
                    Brando16 last edited by

                    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]

                    1 Reply Last reply Reply Quote 0
                    • 1 / 1
                    • First post
                      Last post
                    • When moving a site from HTTP to HTTPS, will i lose value from the 301 redirect?
                      becole
                      becole
                      0
                      4
                      109

                    • Flip-Flopping domains - 301 redirect question
                      OlegKorneitchouk
                      OlegKorneitchouk
                      0
                      6
                      272

                    • HTTPS Login on HTTP Site | 301 or 302 Redirect?
                      Cyrus-Shepard
                      Cyrus-Shepard
                      0
                      4
                      1.2k

                    • Multiple 301 redirects for a HTTPS URL. Good or bad?
                      rishil
                      rishil
                      0
                      6
                      11.4k

                    • Unnatural Links/301 Redirect Question
                      0
                      1
                      100

                    • How to conduct catch 301 redirects & have the separate 301 redirects for the key pages
                      BenRWoodard
                      BenRWoodard
                      0
                      2
                      288

                    • Canonical or 301 redirect, that is the question?
                      X-com
                      X-com
                      0
                      8
                      546

                    • 301 Redirect question
                      webseoservices
                      webseoservices
                      0
                      4
                      438

                    Get started with Moz Pro!

                    Unlock the power of advanced SEO tools and data-driven insights.

                    Start my free trial
                    Products
                    • Moz Pro
                    • Moz Local
                    • Moz API
                    • Moz Data
                    • STAT
                    • Product Updates
                    Moz Solutions
                    • SMB Solutions
                    • Agency Solutions
                    • Enterprise Solutions
                    • Digital Marketers
                    Free SEO Tools
                    • Domain Authority Checker
                    • Link Explorer
                    • Keyword Explorer
                    • Competitive Research
                    • Brand Authority Checker
                    • Local Citation Checker
                    • MozBar Extension
                    • MozCast
                    Resources
                    • Blog
                    • SEO Learning Center
                    • Help Hub
                    • Beginner's Guide to SEO
                    • How-to Guides
                    • Moz Academy
                    • API Docs
                    About Moz
                    • About
                    • Team
                    • Careers
                    • Contact
                    Why Moz
                    • Case Studies
                    • Testimonials
                    Get Involved
                    • Become an Affiliate
                    • MozCon
                    • Webinars
                    • Practical Marketer Series
                    • MozPod
                    Connect with us

                    Contact the Help team

                    Join our newsletter
                    Moz logo
                    © 2021 - 2026 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
                    • Accessibility
                    • Terms of Use
                    • Privacy