Installing WordPress Multiple Times On The Same Site

Installing WordPress multiple times on the same site is real easy. There may be times you want to have two different installs of WordPress on one domain. You can install WordPress on the root of your domain, on a subdomain or in a subdirectory or on all of the above. These, however, will function as completely separate blogs.

If you can create multiple MySQL databases then it’s a pretty straightforward approach just create a new database for each install. But what if you have a limited number of MySQL databases? You can share the database of one WordPress blog with multiple blogs. It just takes one little change in the wp-config.php file to work.

After you have created the new directory for the new WordPress blog you can simple copy the files from the existing blog over to the location of the new blog. But, and this is a very important step to do before the actual install steps! You need to change, or actually create a new database table prefix for the new blog. So before you go through the install steps on the new blog open the wp-config.php file of the new blog and change it.

When you open the wp-config.php file there actually are instructions right in the file to tell you what to do, look for this:

// You can have multiple installations in one database if you give each a unique prefix
$table_prefix = ‘wp_’; // Only numbers, letters, and underscores please!

The part you want to change is the ‘wp_’ part. Make it anything you want and I suggest making it something that corresponds to the new blog so you can easily reference it if you ever need to do any database maintenance.

Disclosure: Some of the links in this article are affiliate links and we may earn a small commission if you make a purchase, which helps us to keep delivering quality content to you. Here is our disclosure policy.

Editorial Staff
Editorial Staff
Editorial Staff at WPArena is a team of WordPress experts led by Jazib Zaman. Page maintained by Jazib Zaman.

LEAVE A REPLY

Please enter your comment!
Please enter your name here
Captcha verification failed!
CAPTCHA user score failed. Please contact us!

spot_img

Related Articles

How to Reduce WordPress Registration Spam

WordPress forms offer a valuable chance for you to connect with your website visitors and potential customers. Those people may...
Read More
Why WordPress is the best CMS? Having a website has become a necessity for both individuals and businesses. Content Management...
When optimizing the speed of your WordPress site, you might come across a performance metric known as Time to First...