In this tutorial we'll teach you how to migrate all the posts from one WordPress to another, using phpMyAdmin. First, we'll locate the database, then find the post tables, export them, and migrate them to the other website.
The job requires some knowledge to avoid mistakes, but the steps are quite simple.
Exporting Posts with phpMyAdmin
The first step is to enter the server control panel and go to the 'phpMyAdmin' service. Once inside, you'll need to find the database; if you don't know which one it is, you can look it up in the 'wp-config.php' file (in the root of the website). Now go to the 'wp_posts' table and you'll find all the 'Posts' of your WordPress. (You won't be backing up comments, authors, or categories.)
Generally you'll find them listed from last to first. To export the database completely, you'll have to click on 'Export' and select the quick method, but to export only the content of 'wp_posts' you have to select 'Custom' and only check 'wp_posts'.
Now you have a '.sql' file where you'll have all the posts of your WordPress website backed up.
Importing into Your New WordPress
At this point you'll have to go to the new WordPress installed on another server, enter the database and the 'wp_posts' table, and then click on 'Import' to upload all the posts to the new page.
Using the WordPress Admin as an Alternative
Remember that if you can access the 'Administrator' of your WordPress, the task is easier. Just go to 'Tools' and then select 'Export'. Here you can back up Posts, Pages, and Media (in full or by date ranges).
Then to import them, just click on 'Tools' and select 'Import', and from the 'WordPress' option you'll have the possibility to download a plugin to upload the '.xml' file.
These options are very good for backing up all the posts of your website built with the WordPress CMS. If the 'Administrator' works for you with the use of a plugin, everything is easier, but if you have to do it natively from the database, we've shown you a simple way that you can do in a few brief steps.
Important Notes
Before ending the tutorial, we remind you that if you have 'Categories', 'Comments', 'Tags', and 'Authors', you'll need to download the corresponding tables (or use the option to export the entire database). Also, if you want to migrate images from one page to another, you'll have to copy the 'images' folder and paste it on the other server (wp-admin/images).