How to Duplicate WordPress Database Using phpMyAdmin
Are you questioning the way to duplicate your WordPress database utilizing phpMyAdmin?
Whether or not you want to arrange an online growth setting or switch your website to a brand new host, you will want to learn to duplicate your WordPress database. If you’re a newbie, the best method to do that is with phpMyAdmin, which is an online utility for managing databases.
On this information, we are going to stroll you thru the step-by-step strategy of duplicating your WordPress database utilizing phpMyAdmin.
Professional Tip: On the lookout for a straightforward method to duplicate your complete web site, together with its database, plugins, themes, content material, and recordsdata? Simply take a look at our information on how to clone a WordPress site with the Duplicator plugin.
Why Ought to You Use phpMyAdmin to Duplicate WordPress Database?
phpMyAdmin is an online utility that helps web site house owners handle their databases.
Primarily, WordPress shops all of your web site content material in a database. When you use a WordPress hosting service, then your knowledge is most definitely saved and arranged in a MySQL database.
The factor is, to work together with MySQL, you’ll sometimes have to be acquainted with command-line instruments, which may be tough if you’re a newbie.
That is the place phpMyAdmin is available in. It has a user-friendly interface that permits you to do numerous database-related duties with out having to put in writing advanced instructions, akin to duplicating your WordPress database. Aside from that, you need to use it to:
With that in thoughts, let’s check out the way to duplicate a WordPress database utilizing phpMyAdmin. We’ll cowl totally different strategies, and you need to use the hyperlinks beneath to shortly bounce to every one:
Methodology 1: Cloning Your WordPress Database With phpMyAdmin
This methodology is appropriate if you wish to manually create a backup or set up a staging environment for testing updates and modifications.
First, it’s good to open your WordPress internet hosting management panel. In our tutorial, we’re working with Bluehost, which makes use of cPanel for its internet hosting account administration. Your management panel might look barely totally different from our screenshots, however the steps shall be related.
As soon as you might be logged in to cPanel, merely discover the phpMyAdmin icon. It’s often contained in the ‘Databases’ part.
Now, you might be inside your hosting’s phpMyAdmin. Right here, simply click on the ‘Databases’ tab on the prime and choose your WordPress database from the listing of databases.
If you’re undecided what your database identify is, it’s the identify you enter whenever you first installed WordPress. You can even discover it in your wp-config.php file in case you overlook.
Subsequent, you will note a listing of your WordPress database tables.
On this web page, simply click on on the ‘Operations’ tab from the highest menu.
That is the place you’ll duplicate your database. Go forward and scroll all the way down to a piece referred to as ‘Copy database to.’
Within the empty discipline, merely write the brand new database identify. Then, be certain that the ‘Construction and knowledge’ field is checked. This feature will copy each the construction and knowledge of the database.
Moreover, the ‘CREATE DATABASE earlier than copying’ choice must be ticked. It will robotically create a brand new database the place the duplicated knowledge shall be situated.
The remainder of the settings may be left as is. All it’s good to do subsequent is click on ‘Go’ on the backside.
And that’s it! Your database has been efficiently cloned.
After this, you possibly can navigate to your newly duplicated database from the left panel.
Methodology 2: Exporting and Importing WordPress Database With phpMyAdmin
This second methodology is greatest in case your internet hosting firm doesn’t permit customers to create databases immediately from phpMyAdmin. This can be the case if you’re utilizing shared hosting services the place sure privileges are restricted for safety causes.
On this state of affairs, it’s possible you’ll not be capable of see the ‘Copy database to’ part within the ‘Operations’ tab. To duplicate your database, you need to use the export methodology as an alternative.
Primarily, you’ll export your database SQL file, arrange a brand new database, after which import that database into the brand new setup.
Step one is to go to phpMyAdmin and choose your WordPress database like we did within the earlier methodology. Then, within the prime menu, merely click on the ‘Export’ button.
Right here, it’s good to choose ‘Customized – show all attainable choices’ within the ‘Export methodology’ part.
As soon as finished, simply scroll to the Output part and select the ‘Save output to a file’ choice. It will ensure that your database is exported as an SQL file.
For the remainder of the settings, you possibly can depart them as they’re.
Now, all you need to do is scroll all the way down to the underside and click on ‘Export.’
Your browser will now obtain the WordPress database as an .sql file.
Subsequent, it’s good to create a brand new database the place you possibly can import this file to.
Go forward and open your internet hosting management panel and click on on ‘MySQL Databases.’
On this web page, it’s good to fill out your new database identify. In our instance, we used _copy
after the unique database identify to distinguish the previous identify from the newly duplicated one.
After that, simply click on the ‘Create Database’ button.
Now that we’ve created a brand new database, let’s assign it to a MySQL user.
Go forward and scroll down the ‘Add Consumer to Database’ part and choose a MySQL username from the dropdown menu. Be sure that to decide on the brand new database you’ve simply created within the ‘Database’ discipline.
As soon as finished, click on ‘Add.’
You’ll now be redirected to the ‘Handle Consumer Privileges’ web page.
Merely verify the ‘ALL PRIVILEGES’ choice if you wish to have whole management over your database.
Then, go all the way in which all the way down to the underside of the web page and click on ‘Make Modifications.’
Your newly created database is now prepared.
Let’s go forward and open phpMyAdmin once more and choose the database you simply created in cPanel.
As soon as inside, you’ll see that the database is empty with out tables like this:
To proceed, merely go to the ‘Import’ web page from the highest menu.
Right here, click on on the ‘Select File’ button to pick the .sql file you downloaded earlier.
As soon as completed, scroll all the way down to the underside and click on the ‘Import’ button.
phpMyAdmin will now add the file out of your pc and import your database.
And that’s all! You might have efficiently imported your duplicated database.
Bonus: Optimize Your WordPress Database for Higher Efficiency
Managing the behind-the-scenes a part of your WordPress web site is simply as vital as the way it seems on the skin. The way you deal with your database impacts how fast your site loads, how safe it’s, and the way simply individuals can use it.
In case your database is cluttered with pointless knowledge, it will probably decelerate your website and make it susceptible to security risks. Usually optimizing your database can forestall this from occurring and make your web site extra dependable.
For extra details about database administration, you possibly can see our newbie’s information on managing a WordPress database with phpMyAdmin and our article on how to optimize your WordPress database with one click.
We hope this text has helped you learn to duplicate a WordPress database utilizing phpMyAdmin. You may additionally wish to see our skilled choose of the best WordPress database management plugins and our tutorial on how to fix the establishing a database connection error in WordPress.
When you favored this text, then please subscribe to our YouTube Channel for WordPress video tutorials. You can even discover us on Twitter and Facebook.