For example, if you have two different WordPress sites and only want to use one of them going forward, you can export the contents of one of the sites and import it to the other site. The Export page can be found at Tools → Export when you’re logged in on the administration panel on your site.
Go to Tools → Export. Select which content you want to include in the export file – all of it, or only a specific content type (like posts or pages). Next, click the blue ”Download Export File” button. Your browser will now download a file with the file suffix ”.xml”. This file contains a copy of all of the content you chose to export from the site.
Next, log in to the administration panel of the site you want to import the content to. Go to Tools → Import, locate “WordPress” in the list, and click the “Install Now” link. When the WordPress Importer plugin has been installed, the link will be replaced by a “Run Importer” link. Click it.
On the next page, select the exported “.xml” file in the file dialog. Next, click the blue “Upload file and import” button. When the upload is completed, you’ll be presented with a couple of options for the import. Choose if you want to create new users to use as authors of the imported content, or if it should be assigned to an existing user. You can also choose to download and import file attachments by checking the corresponding checkbox. If you don’t, the featured images used on the imported posts and pages will not be included in the import.
When you’re done with the settings, click the gray ”Submit” button. Keep the page open until the import has concluded. When it has, the posts, pages and media files included in the export file will have been added to your site.