Domain.com/old-url to domain.com/new-url
-
HI,
I have to change old url`s to new one, for the same domain and all landing pages will be the same:
I have to change to:
All together more than 70.000 url.
What is best way to do that? should I use 301st redirect? is it possible to do in code or how? what could you please suggest?
Thank you, Edgars
-
Great, thanks a lot for your help!!! If you are in Latvia, beer from me ciao and thanks a lot!
-
Yes - you have to update the sitemap with the new url's.
If you don't do it - you'll see that Webmaster tools will generate warnings for every url that is redirected.
Dirk
-
That's correct. If possible - try to do the change on a test server - and try all your existing url's on this test url to be sure that everything is properly redirected (while testing - make sure that the test server doesn't get indexed)
So for domain.com/old-url1 you check if test-server.com/new-url1 is accessible & working - idem for the remainder (screaming frog can do this for you). If everything is properly redirected - you do the change on the production server.
Dirk
-
and one more questions, should we do some changes for site map, if we make 301st redirects? thanks!
-
That was the worst advice somebody could give you... redirecting all old url's to home is the best way for SEO disasters. Glad you double checked!
-
thanks, we change like this:
domain.com/old-url-1 .... to domain.com/new-url1
domain.com/old-url-2 ... to domain.com/new-url-2
etc...
so, we have to use 301st, correct?
-
Thank you! I had recomendation to make like this:
301 redirect to
domain.com/index... all old urls redirected to index page. that was some thing new for me and wanted to know, that this is wrong way.
thanks
E
-
Forgot to mention - there is also a topic on moz on redirects: http://moz.com/learn/seo/redirection - and I also was a bit to fast with my first answer - the rule I gave was if you only change the domain & keep the remainder of the url.
If you also change the directory and the article name, than I hope there is a certain logic between your old structure and the new one. Redirections in htaccess can get quite messy if you have to use many rules inside (they can be in conflict and have an impact on performance).
In each case - you should test all the url's of your old site on the new one (before launch) to be sure that they are all properly redirected. A crawl tool like Screaming Frog can do miracles for testing.
-
If you're on Linux - probably the best way it to change the htaccess file on the old domain:
The .htaccess file needs to be placed in the root directory of your old website (i.e the same directory where your index file is placed)
Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*) http://www.newdomain.com/$1 [R=301,L]Please REPLACE www.newdomain.com in the above code with your actual domain name.
In addition to the redirect I would suggest that you contact every backlinking site to modify their backlink to point to your new website.
Note* This .htaccess method of redirection works ONLY on Linux servers having the Apache Mod-Rewrite moduled enabled.
Disclosure - I didn't invent this myself - source can be found here: http://www.webconfs.com/how-to-redirect-a-webpage.php (this page give all the different options on how to redirect)
rgds,
Dirk
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
-
URL change - Sitemap update / redirect
Hi everyone Recently we performed a massive, hybrid site migration (CMS, URL, site structure change) without losing any traffic (yay!). Today I am finding out that our developers+copy writers decided to change Some URLs (pages are the same) without notifying anyone (I'm not going into details why). Anyhow, some URLs in site map changed, so old URLs don't exist anymore. Here is the example: OLD (in sitemap, indexed): https://www.domain.com/destinations/massachusetts/dennis-port NEW: https://www.domain.com/destinations/massachusetts/cape-cod Also, you should know that there is a number of redirects that happened in the past (whole site) Example : Last couple years redirections: HTTP to HTTPS non-www to www trailing slash to no trailing slash Most recent (a month ago ) Site Migration Redirects (URLs / site structure change) So I could add new URLs to the sitemap and resubmit in GSC. My dilemma is what to do with old URL? So we already have a ton of redirects and adding another one is not something I'm in favor of because of redirect loops and issues that can affect our SEO efforts. I would suggest to change the original, most recent 301 redirects and point to the new URL ( pre-migration 301 redirect to newly created URL). The goal is not to send mixed signals to SEs and not to lose visibility. Any advice? Please let me know if you need more clarification. Thank you
Intermediate & Advanced SEO | | bgvsiteadmin0 -
Website can't break into Google Top100 for main keywords, considering 301 Redirect to a new domain
A little background on our case. Our website, ex: http://ourwebsite.com was officially live in December 2015 but it wasn't On-Site optimized and we haven't done any Off-site SEO to it. In April we decided to do a small redesign and we did it an online development server. Unfortunately, the developers didn't disallow crawlers and the website got indexed while we were developing it on the development server. The development version that got indexed in Google was http://dev.web.com/ourwebsite We learned that it got indexed when we migrated the new redesigned website to the initial domain. When we did the migration we decided to add www and now it looks like: http://www.ourwebsite.com Meanwhile, we deleted the development version from the development server and submitted "Remove outdated content" from the development server's Search Console. This was back in early May. It took about 15-20 days for the development version to get de-indexed and around 30 days for the original website (http://www.ourwebsite.com) to get indexed. Since then we have started our SEO campaign with Press Releases, Outreach to bloggers for Guest and Sponsored Posts etc. The website currently has 55 Backlinks from 44 Referring domains (ahrefs: UR25, DR37) moz DA:6 PA:1 with various anchor text. We are tracking our main keywords and our brand keyword in the SERPs and for our brand keyword we are position #10 in Google, but for the rest of the main (money) keywords we are not in the Top 100 results in Google. It is very frustrating to see no movement in the rankings for the past couple of months and our bosses are demanding rankings and traffic. We are currently exploring the option of using another similar domain of ours and doing a complete 301 Redirect from the original http://www.ourwebsite.com to http://www.ournewebsite.com Does this sound like a good option to you? If we do the 301 Redirect, will the link-juice be passed from the backlinks that we already have from the referring domains to the new domain? Or because the site seems "stuck," would it not pass any power to the new domain? Also, please share any other suggestions that we might use to at least break into the Top 100 results in Google? Thanks.
Intermediate & Advanced SEO | | DanielGorsky0 -
Will have /index in my url hurt?
I am trying to setup permalinks on a wordpress blog that is installed on iis. I can't update the web.config file so I have to make every page /index/pagetitle. as shown here-http://codex.wordpress.org/Using_Permalinks#PATHINFO:_.22Almost_Pretty.22 How much of a difference is there between no /index and having the /index in there?
Intermediate & Advanced SEO | | EcommerceSite0 -
301 Redirect? How to leverage the traffic on our old domain.
I've seen multiple questions about this but there's a few different answers on ways to approach it. Figured I'd personally ask for our situation. Any advice would be appreciated. We formed a new company with a new name / domain while at the same time buying an existing company in our industry. The domain and site of the company we acquired is ranking for some valuable keywords and still getting a significant amount of traffic (about half of what our new site is getting). A big downside has been, when they moved that site to a different server, something happened to where the site became uneducable so it's full of bad pricing and information. Because of that, we've had a maintenance page up for a little bit because it was generating calls to our sales team (GOOD) but the customer was having seen incredibly incorrect information (BAD) Rather than correcting those issues or figuring out why the site is un-editable, we just want to find a way where we can leverage that traffic and have them end up at our new site. Would we 301 redirect the entire domain to our new one? If we did that would the old domain still keep the majority of it's page rank?
Intermediate & Advanced SEO | | HuskyCargo1 -
Does link equity to a page that is 301'd to a new domain pass juice on?
If we build some quality inbound links to certain pages, that are a later date 301'd to another domain, does any equity or juice get transferred across? Or is the inbound link's value wasted? Thanks
Intermediate & Advanced SEO | | bjs20100 -
Sitemaps / Google Indexing / Submitted
We just submitted a new sitemap to google for our new rails app - http://www.thesquarefoot.com/sitemap.xml Which has over 1,400 pages, however Google is only seeing 114. About 1,200 are in the listings folder / 250 blog posts / and 15 landing pages. Any help would be appreciated! Aron sitemap.png
Intermediate & Advanced SEO | | TheSquareFoot0 -
Forwarding Empty URLs to Homepage for SEO & Old Backlink Salvaging - Is there any value or risk?
Our company owns about 30 URLs that we aren't currently using. Is there any SEO value to be gained by forwarding these content-less URLs to our homepage if they aren't currently indexed by google? Some of these sites were previously in use at low traffic volumes by companies who licensed use of our brand and URL. After parting ways a year or longer in the past, no 301 redirection was done to save the link juice, so it's long gone at this point. However, there may be some sites on the net that are still linking to various pages on the URL. What would be the best course of action to salvage any value of these URLs until they are in use again as full websites? Insights would be greatly appreciated! Cheers, Justin
Intermediate & Advanced SEO | | grayline0 -
BIG CHANGE - 301 Main site to new domain
Hi Guys, Were wondering what to do about our main domain name, we were ranking quite high for our main keyword and before Christmas our site dropped to 10th and we have been there for a while - last week our site dropped again onto the second page. The worrying thing is now our main domain name is now ranking 1 place above another domain name that we don't really use but its an exact match domain name for our target keyword. This exact match domain has hardly any links pointing to it and it currently has a 22 domain authority. We are wondering if we 301 our main site to this exact match domain would it rank higher than the top of the 2nd page where we are now for our main domain. Cheers.
Intermediate & Advanced SEO | | ScottBaxterWW1