How do I redirect my old PHP website to my new Java website?
-
Please could you help?
My old website is written in php. I've created a new design of the website in Java. I'll be using the same domain name though.
and I'd like to pass my link juice to my new redesigned website. When I turn the domain name to point to my new website how do I make sure pages that are ranked in google that don't exist on my new website transfer 301 from my old website to a similar page on my new website.
Old Website Example
New Website Example
Many Thanks,
Rob
-
Hi Rob,
I would recommend using htaccess 301 redirects. If you're not currently using htaccess you just need to create a file in your website's root folder and name it .htaccess and jsut add a 301 redirect line for each redirect that you want to do. See below for example.
Redirect 301 /bootcampuk.php /bootcamps.jsp
So it's Redirect 301 Old-Url New-Url
Let me know if you have any questions!
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
-
SEO of blogging websites
What are the best practices of doing SEO of article/blogging websites.
Intermediate & Advanced SEO | | Obbserv0 -
Moving to a new domain name - 301 redirect NOT an option
Hi everyone My question concerns moving from an old to a new domain name without losing all previous SEO efforts. I am aware that a properly executed 301 redirect is the answer and way to go as well as telling Google about it in Webmaster Tools. However, what is the situation, if you do not own the old domain name anymore? If you have no means of getting back the old domain name and wanting to basically mask/switch the already existing website to the new domain name, will search engines penalise the "new site" as a duplicate, since the "old site" is still in the search engine rankings? I know that not being able to execute a proper 301 redirect and starting out with a new domain means a fresh start, but what is the best way to minimise the negative impact (if any)? Basically dropping the sites' current content and starting out new in favour of the new domain name is not really an option. Even if you were to take the content from the old site and place it on another site, this would surely be seen as duplicate too. Anyone thinks that Webmaster Tools/Google is savvy enough to spot the difference when the "old site" gets removed and the "new one" added instead (in Webmaster Tools). I read something along the lines about having your host point the DNS from the old site to the new one. Could something like be helpful? Thanks all in advance for your help and input!
Intermediate & Advanced SEO | | Hermski0 -
Moving half my website to a new website: 301?
Good Morning! We currently have two websites which are driving all of our traffic. Our end goal is to combine the two and fold them into each other. Can I redirect the duplicate content from one domain to our main domain even though the URL's are different. Ill give an example below. (The domains are not the real domains). The CEO does not want to remove the other website entirely yet, but is willing to begin some sort of consolidation process. ABCaddiction.com is the main domain which covers everything from drug addiction to dual diagnosis treatment. ABCdualdiagnosis.com is our secondary website which covers everything as well. Can I redirect the entire drug addiction half of the website to ABCaddiction.com? With the eventual goal of moving everything together.
Intermediate & Advanced SEO | | HashtagHustler0 -
Need help for new website!
I want to a make new website. Can you please advise me what all things are involved which I should keep in mind before and during the website preparation. Like how to make pages, what to include in website, best way to create pages etc. Please provide me the link where I can study all the above information. I am planning to create global printing website.
Intermediate & Advanced SEO | | AlexanderWhite0 -
Strange situation - Started over with a new site. WMT showing the links that previously pointed to old site.
I have a client whose site was severely affected by Penguin. A former SEO company had built thousands of horrible anchor texted links on bookmark pages, forums, cheap articles, etc. We decided to start over with a new site rather than try to recover this one. Here is what we did: -We noindexed the old site and blocked search engines via robots.txt -Used the Google URL removal tool to tell it to remove the entire old site from the index -Once the site was completely gone from the index we launched the new site. The new site had the same content as the old other than the home page. We changed most of the info on the home page because it was duplicated in many directory listings. (It's a good site...the content is not overoptimized, but the links pointing to it were bad.) -removed all of the pages from the old site and put up an index page saying essentially, "We've moved" with a nofollowed link to the new site. We've slowly been getting new, good links to the new site. According to ahrefs and majestic SEO we have a handful of new links. OSE has not picked up any as of yet. But, if we go into WMT there are thousands of links pointing to the new site. WMT has picked up the new links and it looks like it has all of the old ones that used to point at the old site despite the fact that there is no redirect. There are no redirects from any pages of the old to the new at all. The new site has a similar name. If the old one was examplekeyword.com, the new one is examplekeywordcity.com. There are redirects from the other TLD's of the same to his (i.e. examplekeywordcity.org, examplekeywordcity.info), etc. but no other redirects exist. The chances that a site previously existed on any of these TLD's is almost none as it is a unique brand name. Can anyone tell me why Google is seeing the links that previously pointed to the old site as now pointing to the new? ADDED: Before I hit the send button I found something interesting. In this article from dejan SEO where someone stole Rand Fishkin's content and ranked for it, they have the following line: "When there are two identical documents on the web, Google will pick the one with higher PageRank and use it in results. It will also forward any links from any perceived ’duplicate’ towards the selected ‘main’ document." This may be what is happening here. And just to complicate things further, it looks like when I set up the new site in GA, the site owner took the GA tracking code and put it on the old page. (The noindexed one that is set up with a nofollowed link to the new one.) I can't see how this could affect things but we're removing it. Confused yet? I'd love to hear your thoughts.
Intermediate & Advanced SEO | | MarieHaynes0 -
Ajax website and SEO
Hi all, A client of mine has a website similar to Pintrest. All in Ajax/. So imagine an ajax-grid based animal lover site called domain.com. The domain has three different Categories Cats, Dogs, Mice. When you click on a category, the site doesn't handle the URL and doesn't change the domain So instead of the domain going from domain.com to domain.com/cats, it uses the Ajax script and just shows all the cat pins. and when you click on each pin/post it opens a page such as domain.com/Pin/123/PostTitle It doesn't reference the category. However a page domain.com/cats does exist and you can go there directly. Is this an SEO issue for not grouping all pins under a category? How does Google handle Ajax these days, it use to be real bad but if Pintrest is going so well i'm assuming times have changed? Any other things to be wary of for a grid based/ajax site? I am happy to pay for an hour or two for a more in depth audit/tips if you can feed back on the above. Fairly urgent. Thanks
Intermediate & Advanced SEO | | Profero1 -
Transfer link juice from old to new site
Hi seomozzers, The design team is building a new website for one of our clients. My role is to make sure all the link juice is kept. My first question is, should I just make 301s or is there another technique to preserve all the link juice from the old to new site that I should be focusing on? Second Question is that ok to transfer link juice using dev urls like www.dev2.example.com (new site) or 182.3456.2333? or should I wait the creation of real urls to do link juice transfer? Thank you 🙂
Intermediate & Advanced SEO | | Ideas-Money-Art0 -
Have I missed anthing On this website?
Hello SEO MOzzers, I am today wanting your feedback on a site that I recently went live with. My Google rankings for the main keywords are doing very well considering the site has been live for 3 weeks now. I of course have a list of items that i'm still working on, completing meta description tags, title tags, adding copy content to category pages, updating h1 tags, working on our backlinking campaign, etc. Is there anthing any of you SEO Mozzers can see that I may have missed? the web domain is www.carbodypanels4u.co.uk Keywords "body Panels"
Intermediate & Advanced SEO | | seohive-222720
"car body panels"
"Car Make body panels"
"Car make Model body panel" Im sure you get the gist of the keyword structure. Your feedback is much appreciated as always. shiv0