• Skip to main content
  • Skip to primary sidebar
BMA

BeMyAficionado

Inspire Affection

Port Existing Website to WordPress

May 7, 2016 by varunshrivastava 1 Comment

First of all, I would like to apologise to all my reader for any inconvenience caused during all the porting process. It wasn’t easy for me as I was doing something like this for the first time. I sure knew the basics theoretically but missing out on the practical knowledge. It took me about a week’s time to get it all up and running. And finally, when it’s finished, I could finally write my blogs again :). It requires a-lot to port your existing website to wordpress or some different platform.

In this article, I would like to share my practical knowledge which would help you in the future. Here’s the list of problems that you might face while porting your website to some other domain or to some other platform altogether, (just like in my case).

Table of Contents

  • Port Existing Website to WordPress Requires –
    • Page Redirects
    • Database Porting
    • Minimum Website Downtime
  • Conclusion

Port Existing Website to WordPress Requires –

  • Preserving Google Page Rank
  • Thorough Understanding of different types of redirects
  • Logic Formulation
  • Porting Database (if you are porting to another platform)
  • Minimum Website Downtime
  • Maintain a Good User Experience

The very first problem that was in front of me was the Google Ranking. You wouldn’t want to make Google sad, it may badly affect your website’s visibility. Hopefully, Google provides solutions for this problem. All you need to do is provide the new address for the moved pages to Google. This is really simple to do, all you need is to give a “301 redirect” to the new page address. If you are porting your existing website to some other domain, i.e, from www.example.com to www.differentexample.com then it becomes easier compared to the situation when you have to port your entire website to another platform or you may have to move your website to a new place inside your server. Both the situation have their pros and cons.

Porting to a different domain
The problems related to this situation are –

  • Page Redirects
  • Database Porting

Page Redirects

301 Redirect

You bought a new domain and hosted your new website there. Once your website is up and running, then you simply start redirecting your old website URLs to their new address without making any major changes to your website. You may have to come up with a redirection logic, which will solely depend on your project’s structure. Suppose, your old website blog URLs are shown in this format, www.oldwebsite.com/blog/123/port-website and your new website’s URLs format is www.newwebsite.com/port-website, then, in this case, you may use .htaccess file to redirect pages that match this particular pattern to their new home. You could simply write a redirect rule like the one below,

RewriteEngine on
RedirectRule ^blog/[0-9]+/([a-zA-Z0-9-]+)/?$ HTTP://www.newwebsite.com/$1 [R=301,L]

if you want to read more about redirection rules, you may follow this link, URL Rewriting for the fearful.

So, that was easy, Right? Now, you are left with the database porting part.

Database Porting

Port Database

Database porting is a tedious task, if you are porting the website to a similar platform like, from WordPress to WordPress then it may not cause you much trouble, but if you are porting to a whole different platform then you must look for some innovative ways to do that. You may search for some existing Softwares to make your job easy or you can walk the path I did. I’m running the old and new website together :D. I created a different database for my older website and simply imported the database there. I let my old website serve the way it was doing before and created a different database for WordPress. So, my website’s structure is pretty much the mixture of old and new.

One may ask about the performance factor for doing something like this, well, there’s not much difference in the performance because I haven’t tweaked with the core files. So basically, there are two different websites operating under the same domain. By-the-way you can take a look by yourself, here’s the link to my older website My Old Website, you may discuss more in the comments below.

Minimum Website Downtime

Another important thing to consider here is the downtime of your website. You may not want to make a bad impression for a new visitor. A returning visitor may know you and understand the downtime for a website but it will leave a bad impression on a new potential visitor. On top of this, it can also affect your Google Page Ranking. There are solutions to let google know that your website is under a temporary maintenance and that you can do with a “503 Status Code”. It simply states that the server is currently unable to handle the request due to a temporary overloading or maintenance of the server. You can also tell the crawlers about the retry time. You may use the below code snippet to return a 503 status code on your page.

header(‘HTTP/1.1 503 Service Temporarily Unavailable’);
header(‘Status: 503 Service Temporarily Unavailable’);
header(‘Retry-After: 300’);//300 seconds

Conclusion

By taking care of these simple steps, you can easily port your website to a new server or domain by keeping the integrity of your website intact. I learned these things by doing them practically and there will be lots of hidden traps that you might face, so my advice to you all is to plan ahead. This article was just an overview of all the problems that you might face, there are differents tastes to these problems as well. I will write another article about the problems I faced and what I did to solve them. I hope you had a great experience reading this article.

One Life, Rise and Shine

cheers 🙂

Related

Filed Under: Wordpress N SEO Tagged With: 301, 503, database, htaccess, redirects, status codes, website, wordpress

Primary Sidebar

Subscribe to Blog via Email

Do you enjoy the content? Feel free to leave your email with me to receive new content straight to your inbox. I'm an engineer, you can trust me :)

Join 874 other subscribers

Latest Podcasts

Recent Posts

  • Is The Cosmos a Vast Computation?
  • Building Semantic Search for E-commerce Using Product Embeddings and OpenSearch
  • Leader Election with ZooKeeper: Simplifying Distributed Systems Management
  • AWS Serverless Event Driven Data Ingestion from Multiple and Diverse Sources
  • A Step-by-Step Guide to Deploy a Static Website with CloudFront and S3 Using CDK Behind A Custom Domain

Recent Comments

  • Varun Shrivastava on Deploy Lambda Function and API Gateway With Terraform
  • Vaibhav Shrivastava on Deploy Lambda Function and API Gateway With Terraform
  • Varun Shrivastava on Should Girls Wear Short Clothes?
  • D on Should Girls Wear Short Clothes?
  • disqus_X5PikVsRAg on Basic Calculator Leetcode Problem Using Object-Oriented Programming In Java

Categories

  • Blogging
  • Cooking
  • Fashion
  • Finance & Money
  • Programming
  • Reviews
  • Software Quality Assurance
  • Technology
  • Travelling
  • Tutorials
  • Web Hosting
  • Wordpress N SEO

Archives

  • November 2024
  • September 2024
  • July 2024
  • April 2024
  • February 2024
  • November 2023
  • June 2023
  • May 2023
  • April 2023
  • August 2022
  • May 2022
  • April 2022
  • February 2022
  • January 2022
  • November 2021
  • September 2021
  • August 2021
  • June 2021
  • May 2021
  • April 2021
  • February 2021
  • January 2021
  • December 2020
  • November 2020
  • October 2020
  • September 2020
  • August 2020
  • July 2020
  • June 2020
  • May 2020
  • April 2020
  • February 2020
  • December 2019
  • November 2019
  • October 2019
  • August 2019
  • July 2019
  • June 2019
  • May 2019
  • April 2019
  • March 2019
  • January 2019
  • November 2018
  • October 2018
  • September 2018
  • August 2018
  • July 2018
  • June 2018
  • May 2018
  • March 2018
  • February 2018
  • January 2018
  • December 2017
  • November 2017
  • October 2017
  • September 2017
  • August 2017
  • July 2017
  • June 2017
  • May 2017
  • April 2017
  • March 2017
  • February 2017
  • January 2017
  • December 2016
  • November 2016
  • October 2016
  • September 2016
  • August 2016
  • July 2016
  • June 2016
  • May 2016

Tags

Affordable Hosting (4) algorithms (4) amazon (3) aoc-2020 (7) believe in yourself (4) best (4) database (4) earn money blogging (5) education (4) elementary sorting algorithms (4) experience (3) fashion (4) finance (6) Financial Freedom (7) food (7) friends (3) goals (5) google (5) india (10) indian cuisine (5) indian education system (4) java (16) life (16) life changing (4) love (4) make money (3) microservices (9) motivation (4) oops (4) podcast (6) poor education system (4) principles of microservices (5) problem-solving (7) programmer (5) programming (28) python (5) reality (3) seo (6) spring (3) success (10) success factor (4) technology (4) top 5 (7) typescript (3) wordpress (7)

Copyright © 2025 · Be My Aficionado · WordPress · Log in

Go to mobile version