undefined
Skip to content
Moz logo Menu open Menu close
  • Products
    • Moz Pro
    • Moz Pro Home
    • Moz Local
    • Moz Local Home
    • STAT
    • Moz API
    • Moz API Home
    • Compare SEO Products
    • Moz Data
  • Free SEO Tools
    • Domain Analysis
    • Keyword Explorer
    • Link Explorer
    • Competitive Research
    • MozBar
    • More Free SEO Tools
  • Learn SEO
    • Beginner's Guide to SEO
    • SEO Learning Center
    • Moz Academy
    • SEO Q&A
    • Webinars, Whitepapers, & Guides
  • Blog
  • Why Moz
    • Agency Solutions
    • Enterprise Solutions
    • Small Business Solutions
    • Case Studies
    • The Moz Story
    • New Releases
  • Log in
  • Log out
  • Products
    • Moz Pro

      Your all-in-one suite of SEO essentials.

    • Moz Local

      Raise your local SEO visibility with complete local SEO management.

    • STAT

      SERP tracking and analytics for enterprise SEO experts.

    • Moz API

      Power your SEO with our index of over 44 trillion links.

    • Compare SEO Products

      See which Moz SEO solution best meets your business needs.

    • Moz Data

      Power your SEO strategy & AI models with custom data solutions.

    NEW Keyword Suggestions by Topic
    Moz Pro

    NEW Keyword Suggestions by Topic

    Learn more
  • Free SEO Tools
    • Domain Analysis

      Get top competitive SEO metrics like DA, top pages and more.

    • Keyword Explorer

      Find traffic-driving keywords with our 1.25 billion+ keyword index.

    • Link Explorer

      Explore over 40 trillion links for powerful backlink data.

    • Competitive Research

      Uncover valuable insights on your organic search competitors.

    • MozBar

      See top SEO metrics for free as you browse the web.

    • More Free SEO Tools

      Explore all the free SEO tools Moz has to offer.

    NEW Keyword Suggestions by Topic
    Moz Pro

    NEW Keyword Suggestions by Topic

    Learn more
  • Learn SEO
    • Beginner's Guide to SEO

      The #1 most popular introduction to SEO, trusted by millions.

    • SEO Learning Center

      Broaden your knowledge with SEO resources for all skill levels.

    • On-Demand Webinars

      Learn modern SEO best practices from industry experts.

    • How-To Guides

      Step-by-step guides to search success from the authority on SEO.

    • Moz Academy

      Upskill and get certified with on-demand courses & certifications.

    • SEO Q&A

      Insights & discussions from an SEO community of 500,000+.

    Unlock flexible pricing & new endpoints
    Moz API

    Unlock flexible pricing & new endpoints

    Find your plan
  • Blog
  • Why Moz
    • Small Business Solutions

      Uncover insights to make smarter marketing decisions in less time.

    • Agency Solutions

      Earn & keep valuable clients with unparalleled data & insights.

    • Enterprise Solutions

      Gain a competitive edge in the ever-changing world of search.

    • The Moz Story

      Moz was the first & remains the most trusted SEO company.

    • Case Studies

      Explore how Moz drives ROI with a proven track record of success.

    • New Releases

      Get the scoop on the latest and greatest from Moz.

    Surface actionable competitive intel
    New Feature

    Surface actionable competitive intel

    Learn More
  • Log in
    • Moz Pro
    • Moz Local
    • Moz Local Dashboard
    • Moz API
    • Moz API Dashboard
    • Moz Academy
  • Avatar
    • Moz Home
    • Notifications
    • Account & Billing
    • Manage Users
    • Community Profile
    • My Q&A
    • My Videos
    • Log Out

The Moz Q&A Forum

  • Forum
  • Questions
  • Users
  • Ask the Community

Welcome to the Q&A Forum

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

  1. Home
  2. Research & Trends
  3. White Hat / Black Hat SEO
  4. How to 301 redirect from old domain and their pages to new domain and pages?

Moz Q&A is closed.

After more than 13 years, and tens of thousands of questions, Moz Q&A closed on 12th December 2024. Whilst we’re not completely removing the content - many posts will still be possible to view - we have locked both new posts and new replies. More details here.

How to 301 redirect from old domain and their pages to new domain and pages?

White Hat / Black Hat SEO
2
9
7.8k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as question
Log in to reply
This topic has been deleted. Only users with question management privileges can see it.
  • andzon
    andzon last edited by Aug 21, 2014, 5:45 AM

    Hi i am a real newbie to this and i hope for a guide on how to do this. I seen a few moz post and is quiet confusing hopefully somebody able to explain it in layman terms to me.

    I would like to  301 redirect this way, both website contain the same niche.

    oldwebsite.com > newwebsite.com

    and also its pages.....

    oldwebsite.com/test >newwebsite.com/test

    So my question here is i would like to host my old domain and its pages in my new website hosting in order to redirect to my new domain and its pages

    how do i do that? would my previous page link overwrite my new page link? or it add on the juice link?

    Do i need to host the whole old domain website into my new hosting in order to redirect the old pages?

    really confusing here, thanks!

    1 Reply Last reply Reply Quote 0
    • andzon
      andzon @masoudfatemi last edited by Aug 21, 2014, 7:34 AM Aug 21, 2014, 7:34 AM

      i tried pasting that code there and change the old domain and new domain but it doesnt work

      1 Reply Last reply Reply Quote 0
      • masoudfatemi
        masoudfatemi last edited by Aug 21, 2014, 6:55 AM Aug 21, 2014, 6:55 AM

        Yes. you should move your contents to your new host and redirect your old domain to new one.

        andzon 1 Reply Last reply Aug 21, 2014, 7:34 AM Reply Quote 0
        • andzon
          andzon @masoudfatemi last edited by Aug 21, 2014, 6:53 AM Aug 21, 2014, 6:53 AM

          by parking the domain in the new hosting, all my previous pages will be gone right? unless i move everything from the old server to the new one? so i can redirect those pages to my new one too

          1 Reply Last reply Reply Quote 0
          • masoudfatemi
            masoudfatemi last edited by Aug 21, 2014, 6:44 AM Aug 21, 2014, 6:44 AM

            Yes. Simply park your domain on your new hosting and redirect it using this code.

            andzon 1 Reply Last reply Aug 21, 2014, 6:53 AM Reply Quote 0
            • andzon
              andzon @masoudfatemi last edited by Aug 21, 2014, 6:38 AM Aug 21, 2014, 6:38 AM

              do we need to keep this redirect permanently? for example to keep the hosting on in order for it to redirect it to my new site.

              1 Reply Last reply Reply Quote 0
              • masoudfatemi
                masoudfatemi last edited by Aug 21, 2014, 6:23 AM Aug 21, 2014, 6:23 AM

                yes; all of your old links move to new domain without hurting your SEO. Its a permanent redirection called 301.

                andzon 1 Reply Last reply Aug 21, 2014, 6:38 AM Reply Quote 0
                • andzon
                  andzon @masoudfatemi last edited by Aug 21, 2014, 6:21 AM Aug 21, 2014, 6:21 AM

                  by using this code

                  Options +FollowSymlinks
                  RewriteEngine On
                  RewriteCond %{HTTP_HOST} ^olddomain.com [NC]
                  RewriteRule ^(.*)$ http://newdomain.com/$1 [L,R=301]

                  how would it affect my seo? would it merge from the old link to the new link?

                  1 Reply Last reply Reply Quote 0
                  • masoudfatemi
                    masoudfatemi last edited by Aug 21, 2014, 5:51 AM Aug 21, 2014, 5:51 AM

                    Hi

                    its better to ask instead of not asking 🙂

                    First, you should host your old domain on your new site and use this htaccess code to redirect 301 all your urls to new domain(don't forget to change newdomain.com and yourdomain.com with your new and old site):

                    Options +FollowSymlinks
                    RewriteEngine On
                    RewriteCond %{HTTP_HOST} ^olddomain.com [NC]
                    RewriteRule ^(.*)$ http://newdomain.com/$1 [L,R=301]

                    RewriteCond %{HTTP_HOST} ^www.olddomain.com [NC]
                    RewriteRule ^(.*)$ http://newdomain.com/$1 [L,R=301]

                    then you should submit a request in webmaster tools > change of address part to move your site authority completely.

                    andzon 1 Reply Last reply Aug 21, 2014, 6:21 AM Reply Quote 0
                    • 1 / 1
                    1 out of 9
                    • First post
                      1/9
                      Last post

                    Got a burning SEO question?

                    Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.


                    Start my free trial


                    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.

                    • See all categories

                    Related Questions

                    • MarkHodson

                      Is this campaign of spammy links to non-existent pages damaging my site?

                      My site is built in Wordpress. Somebody has built spammy pharma links to hundreds of non-existent pages. I don't know whether this was inspired by malice or an attempt to inject spammy content. Many of the non-existent pages have the suffix .pptx. These now all return 403s. Example: https://www.101holidays.co.uk/tazalis-10mg.pptx A smaller number of spammy links point to regular non-existent URLs (not ending in .pptx). These are given 302s by Wordpress to my homepage. I've disavowed all domains linking to these URLs. I have not had a manual action or seen a dramatic fall in Google rankings or traffic. The campaign of spammy links appears to be historical and not ongoing. Questions: 1. Do you think these links could be damaging search performance? If so, what can be done? Disavowing each linking domain would be a huge task. 2. Is 403 the best response? Would 404 be better? 3. Any other thoughts or suggestions? Thank you for taking the time to read and consider this question. Mark

                      White Hat / Black Hat SEO | Apr 4, 2019, 7:30 AM | MarkHodson
                      0
                    • HuptechWebseo

                      Do we lose Backlinks and Domain Authority of URL when we change domain Name?

                      Have 1 performing domain (Monthly - 4M visitor ) now we want to change domain name ( Brand name like SEOMOZ to Moz ). I have general knowledge about domain changing prevention tips like 301 redirection and other thing. My concern is about backlinks and DA. How can I prevent any lose from SEO Point of view. (backlink lose) Do I need to change all backlink form source or redirection is enough to get all reference traffic from that backlinks?

                      White Hat / Black Hat SEO | Aug 4, 2018, 8:59 PM | HuptechWebseo
                      0
                    • remkoallertz

                      Acquire domains to boost yours, how to redirect an acquired domain

                      What is the best way to redirect for best SEO benefits? Examples: glaspunt.nl -> glas.nl fietstassen.eu -> loodgieter.nl Any technical information how to (root) redirect for best SEO practices?

                      White Hat / Black Hat SEO | Jan 12, 2015, 5:21 AM | remkoallertz
                      0
                    • andzon

                      How would you optimize a new site?

                      Hi guys, im here to ask based on your personal opinion. We know in order to rank in SEO for a site is to make authority contents that interest people. But what would you do to increase your ranking of your site or maybe a blog post? leaving your link on blogs comment seem dangerous, nowadays. Is social media the only way to go? Trying to get people to write about you? what else can be done?

                      White Hat / Black Hat SEO | Aug 4, 2014, 4:38 AM | andzon
                      0
                    • crescentdigital

                      Suspicious external links to site have 302 redirects

                      Hi, I have been asked to look at a site where I suspect some questionable SEO work, particularly link building. The site does seem to be performing very poorly in Google since January 2014, although there are no messages in WMT. Using WMT, OPenSiteExplorer, Majestic & NetPeak, I have analysed inbound links and found a group of links which although are listed in WMT, etc appear to 302 redirect to a directory in China (therefore the actual linking domain is not visible). It looks like a crude type of link farm, but I cant understand why they would use 302s not 301s. The domains are not visible due to redirects. Should I request a disavow or ignore? The linking domains are listed below: http://www.basalts.cn/
                      http://www.chinamarbles.com.cn/
                      http://www.china-slate.com.cn/
                      http://www.granitecountertop.com.cn/
                      http://www.granite-exporter.com/
                      http://www.sandstones.biz/
                      http://www.stone-2.com/
                      http://www.stonebuild.cn/
                      http://www.stonecompany.com.cn/
                      http://www.stonecontact.cn/
                      http://www.stonecrate.com/
                      http://www.stonedesk.com/
                      http://www.stonedvd.com/
                      http://www.stonepark.cn/
                      http://www.stonetool.com.cn/
                      http://www.stonewebsite.com/ Thanks Steve

                      White Hat / Black Hat SEO | Jul 18, 2014, 10:12 AM | crescentdigital
                      0
                    • Sir

                      Why does expired domains still work for SEO?

                      Hi everyone I’ve been doing an experiment during more than 1 year to try to see if its possible to buy expired domains. I know its considered black hat, but like I said, I wanted to experiment, that is what SEO is about. What I did was to buy domains that just expired, immediately added content on a WP setup, filled it with relevant content to the expired domain and then started building links to other relevant sites from these domains.( Here is a pretty good post on how to do, and I did it in a similar way. http://searchenginewatch.com/article/2297718/How-to-Build-Links-Using-Expired-Domains ) This is nothing new and SEO:s has been doing it for along time. There is a lot of rumors around the SEO world that the domains becomes worthless after they expire. But after trying it out during more than 1 year and with about 50 different expired domains I can conclude that it DOES work, 100% of the time. Some of the domains are of course better than others, but I cannot see any signs of the expired domains or the sites i link to has been punished by Google. The sites im liking to ranks great ONLY with those links 🙂 So to the question: WHY does Google allow this? They should be able to see that a domain has been expired right? And if its expired, why dont they just “delete” all the links to that domain after the expiry date? Google is well aware of this problem so what is stopping them? Is there any one here that know how this works technically?

                      White Hat / Black Hat SEO | Jan 27, 2014, 7:54 PM | Sir
                      0
                    • FinanceSite

                      Separate domain name for a subdomain?

                      I just created a subdomain to help our main TLD website. I was wondering if it's smart to create a separate TLD for this subdomain and set up a forward and build links to it. Reason I was thinking about it because it would be easier for people to remember instead of typing in subdomain.maindomain.com. But, I don't want the main website to suffer, since the purpose of creating this subdomain and it's content is to help the main domain. Any inputs on this? Thank you.

                      White Hat / Black Hat SEO | Mar 26, 2012, 3:32 PM | FinanceSite
                      0
                    • phatride

                      Can you block backlinks from another domain

                      Wondering if this is somehow possible. A site got hacked and created a /data folder with hundreds of .php files that are web pages selling all sorts of stuff. We deleted the /data folder and blocked Google from indexing it. Just noticed in Webmaster Tools that the site has 35,000 backlinks from other sites that got hacked with the same way. Is there a way to block these sites? I am assuming there isn't, but wanted to see if anyone ran into the same problem. It is a wordpress site is that helps.

                      White Hat / Black Hat SEO | Nov 26, 2011, 12:23 AM | phatride
                      0

                    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
                    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 - 2025 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
                    • Accessibility
                    • Terms of Use
                    • Privacy

                    Looks like your connection to Moz was lost, please wait while we try to reconnect.