How to export a WordPress site

Last updated on August 18, 2021

How to export a WordPress site

Exporting a WordPress site is needed when migrating your site to a new domain or a web host, creating a backup, or saving your blog posts on your computer. There are multiple WordPress exporter tools that let you export your website files, WordPress database, themes, plugins, and media as a whole.

WordPress’s basic export feature

First, let us have a look at the most basic way of exporting site data. This in-built export tool of WordPress lets you export the database. To proceed with this method:

  • Go to the WordPress admin panel.
  • Click on Tools > Export.
  • Select the ‘All Content’ option.
Basic export feature of WordPress

‘All Content’ option exports all the posts, pages, comments, custom fields, categories, tags, navigation menus, and custom posts.

  • Click on Download Export File.

A copy of your site gets created in an XML format. Once the download file is saved, use the Import function in the other WordPress installation to import the content.

Exporting WordPress Site As A Whole

Along with the database, if you want to export the theme, media library, plugins. That is, the whole WordPress site, then opt for either of these two methods.

  • Method 1: Exporting with the WordPress migrator plugin
  • Method 2: Exporting manually with FTP and phpMyAdmin

Method1: Exporting with the WordPress migrator plugin

The WordPress migrator plugin will make your WordPress import and export operations quick and easy. With a single click, you can backup and migrate the WordPress site’s media files, plugins, and themes, as well as the database.
To export using the plugin:

  1. Install and activate the plugin. 
  2. From the WordPress admin panel, click on WordPress Migration> Export.
  3. Find and Replace the database text and export all the wp-contents in a zip format.

Find and Replace Database Text

The find and replace feature helps you replace any text within the database file to match the destination website for a smoother import. It searches for the ‘Find’ value in the database and replaces it with the specified ‘Replace with’ value. 

Example: If you are migrating data from an existing domain (https://www.myolddomain.com) to a new domain (https://www.mynewdomain.com), use “Find” text as https://www.myolddomain.com and “Replace with” text as https://www.mynewdomain.com.

You can carry out multiple ‘Find and Replace’ operations by clicking on the ‘+’ button on the right.

find-and-replace
Adding-filter
Adding filter `wt_mgdp_exclude_files`

Export storage options (defaulted to local)

You can choose among the following destinations to which the file is to be exported:

  • Local
  • FTP
  • Google Drive
  • Amazon S3
Export storage options in migrator plugin

Exclude Folder/Files to Export

Select the folders or files you want to exclude while exporting.

Exclude Folder/Files to Export

Select all these folders and files if you want to export only the database. Once you finish the setup, proceed to click the Export button in the end. 

For more details, refer to: WordPress Backup & Migration – User Guide.

The WordPress Migrator and Duplicator is a free plugin from WebToffee. The premium version of the migrator plugin is on its way with a lot more features.

Method2: Exporting manually with FTP and phpMyAdmin

Exporting through using FTP and phpMyAdmin is the last option as this has to be done manually. Moreover, many users, especially beginners may find this approach a bit difficult. However, we have explained the export steps in the simplest way possible to get your work done with ease.

Steps To Connect

  1. Connect to your existing site’s server using FTP. To proceed, you may need:
    • FTP client
    • FTP credentials
      Here, we are using FileZilla as the FTP client. FTP credentials include host, username, password, and port. These details are provided by the web host and will be listed in your hosting account.

  2. Enter the credentials.
  3. Click on Quickconnect.
    Quickconnect-in-fileZilla
    On successful connection, multiple folders will appear on the right-hand side of the interface.

  4. Spot the site’s root folder. Generally labeled as public_html (or as site’s domain name). All your site’s files are stored here.
  5. Drag and drop the required content from the server to your local computer on the left hand side.
Connected to FileZilla

Exporting WordPress Plugins, Themes, And Media Files

To export, all your plugins, themes, and media files:

  • Drag and drop wp-content. All the required data will get downloaded.
FTP- Drag and drop wp-content

To migrate or back up the entire site:

  • Highlight everything in the public_html directory.
  • Drag the same to your local computer.  

All your site’s files will get exported.

Steps To Export Database in phpMyAdmin

  1. Click on the tab: Export.
  2. Select the export method.
  3. Select the format as SQL.
  4. Click on Go.
Exporting database in sql format

This will download the database.

Wrap Up

Having a backup or exporting the WordPress site is vital when you  ever encounter a conflict or when moving your WordPress  site to a new domain. Irrespective of your technical skills, the smartest way to do this job is choosing the WordPress migration plugin. Do share your queries in the comment section. We will definitely get back to you at the earliest. Have a trouble free export!