I am asked to migrate an existing website to a CMS (Joomla / Drupal). The current website is on a shared hosting and there are already lots of files inside the public_html folder.

I am thinking of doing the migration in the following way.

1) Install the CMS on my machine.

2) Create a CMS theme from the old website.

3) Copy all contents from the old website to the CMS.

4) Backup everything in the old website.

5) Remove the old website by cleaning up everything in the hosting account, which includes the files inside the public_html folder and the all tables in the mysql database.

6) Transfer all files in the public_html folder on my machine to the public_html folder in the shared hosting by FTP.

7) Backup the mysql database (the CMS must have created lots of tables and data rows) on my machine.

8) Restore the database in the shared hosting using PHPMyAdmin.

9) Test if everything still works after the migration.

I think there are just too many steps.

Is this the way you would handle a website migration to a CMS?

Many thanks to you all.

1 Answer 1


There's no magical way to turn a website migration into a 3-step process, but with planning and some clever scripting, you can make things go a lot more smoothly.

First things first, is this a static site we're talking about or a dynamic site? There's a reason why most sites these days are dynamic. It's just impractical to manage and maintain a large site comprised of static pages. So if that's what you're dealing with, then unfortunately things will be a lot tougher. Otherwise, you can probably export the existing site's content into a common format and import it into the new CMS.

However, if you're dealing with a static site, I'd take one of two approaches. The first approach is to write a script that processes the static pages, extracts the contents, and then imports it into the new CMS. The quickest way to do this with bulk data is to extract it into a CSV file, and then when you've extracted all the data, use LOAD DATA INFILE to load all of the data in one go.

However, if the site was poorly kludged together and the pages are just too irregular/non-normal to process with a script (broken markup, different document structure on each page, etc.) then you'll need to do it by hand. In this case, I would just source the mindless data-entry work to someone else. You could even just advise the client to have their secretary do it. Otherwise, you could out source it and bill the client.

Secondly, before you make the migration, map out all of the old URLs to the corresponding pages on the new site. This is a critical planning step that a lot of people overlook, and it costs them a lot of lost traffic as well as years of SEO/SEM investment and PageRank. Pay particular attention to the high traffic/value pages. Which pages have the most backlinks? What are the pages receiving the most organic search traffic? What pages contribute to high conversion rates? Figure all of this out in your planning stage and make the appropriate 301 redirects to your new site structure. You don't want people clicking on an old bookmark and going to a 404 page.

Lastly, if you have an accommodating hosting plan, do not install the new site in the same directory as the existing site. What I like to do is create a new wwwroot folder (e.g. /www/mycompany.com-2.0) for the new site and assign it to a test domain (e.g. test.mycompany.com). Then you can test the new site out on your production server while the old site is still up (unless you're using virtualization to maintain identical hardware & software configurations between your production and test servers, you can't be sure that they'll behave the same). Once you've tested it out there, then simply change your Apache/IIS configurations so that the actual company domain is hosted out of the new directory.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.