Create a Staging Site for Drupal - Existing Domain

What would be the best way to setup a staging site for an existing NON drupal site on DH, where I can install Drupal, build the Drupal site, and then when ready, “migrate” it in the easiest fashion to the existing live DH hosted

Has anyone done this here? I am familiar with the usage of subdomains… How would I accomplish this using them in the easiest fashion with a DB driven site like Drupal?


It’s be easiest to install it as a subdomain of your domain, so

When you’re ready to go live:

  1. If you want to maintain its One-Click status so you can do One-Click upgrades, back up your main site and then delete it from the panel. And then create your domain using the Mirror option so it points to your subdomain.

  2. If you want the cleanest setup and can live without the One-Click upgrades, FTP to your server and use the rename function on the directories holding your sites: Rename to example.old | Rename to | Rename example.old to beta.example.old (just to keep it alive). And then go into your sites and clean up any improper URL references.

I wont be using the One-Click since we want to install a custom theme etc…
So, from your helpful suggestion I think I would…
1- Create the subdomain of my live site -
2- Install Drupal there
3- Build and Test
4- When ready to push it live:
5-Make a file backup of live site anyhow
6-Delete the Hosting account in the panel? (might need some explanation here…)
7-use the mirror function to present when is requested?
Leave that Subdomain in place always, huh?

Thanks a lot for the help.

Since it’s not One-Click, go with #2, which involves the directory rename. Don’t do #6 or #7

Do 1–5.
6- FTP to your server and do the renames: -> example.old, ->
7- Edit your Drupal site so it uses the new URL ( instead of This may be in a config file, or through the admin panel in Drupal.

Thanks Much appreciated!
Have a great Weekend,

hey there. i had almost the exact same question. prior to reading this thread, i had been thinking of:

Want to migrate from another hosting provider. Prior to flipping dns:

  1. Setup a mirrored site:
  2. Setup a new mirrored mysql database:
  3. Install Drupal (custom, not 1-click) in this mirrored environment - referencing the - during installation.
  4. Build out the site, test and gain approval.
  5. Flip dns from old host provider to this new site.

So, I’ve never done anything like this before, and I’m a little uncertain about:

  1. Whether this is viable
  2. What happens/what to expect after the dns flip. (e.g. Will there be housekeeping req’d?)
  3. Per step 3 above, when installing drupal it asks you to point it to the mysql instance it will use, writing this reference into the data. When this gets repointed to the proper mysql instance, what happens to these references?

Wondering how you (James) made out with the suggested approach. And/or if anyone wants to weigh in on this (different) approach.
Thanks a lot to any and all for any info.

Hi there. Regarding the Database, actually you dont have to change anything. If the mirror on DH is set to mirror the actual hostname to the subdomain. then the domainname will resolve to the files in the subdomain where you did all the staging work, and hence the database connection, but appear to be at

I didnt intend to have a different database for my staging site vs. my live site.

I would like to go in and do the correct housekeeping to be able to have the DRUPAL site/files under the Fully Qualified Domain name and not the subdomain any longer but I’m not sure what that entails to be honest. Scott said that you can:
“7- Edit your Drupal site so it uses the new URL ( instead of This may be in a config file, or through the admin panel in Drupal.”

But I do believe you can run it on the Subdomain being mirrored from the true domain indefinately.
Lets talk more as I would like some added info on this myself.
So far my project worked out fine as I described above. When I flipped the DNS the DRUPAL site at (mirror of actual domain) shows!

i am very new to drupal and feel like i am slogging through mud.

reading the post by sdayman, i get the sense that i will need to
install drupal for each website that i create on DH? currently, i
have multiple domains and if all goes well with my initial foray
into drupal, i will be using it for other domains on DH.

thanks for any help!

This sounds like you want to run Drupal in Multisite mode. Here’s a little information on it:

Maybe I like doing extra work, so I’ve avoided multi-site installations. Individual setups let me customize each one the way I want.

that’s a good tip! thanks for your quick reply.