How To Migrate WooCommerce Customers and Orders (Like A Pro!)
How to move customers and orders in WooCommerce from one site to another?
In this guide, you will learn how to successfully migrate WooCommerce customers and orders between sites without changing the customer’s password or over writing existing orders and post IDs.
Whether you need to move a few or thousands of WooCommerce customers and orders between sites, you are in good hands!
Remember to stay patient, take backups after each step, and practice on different staging sites if need be.
What is the process to migrate WooCommerce customers and orders from site to site?
- Export Customers from Site A
- Import Customers to Site B
- Export Orders from Site A
- Import Orders to Site B
Make sure to migrate your customers before migrating your orders. How come? Each order is mapped to a single customer. If the customer has not been migrated yet, the order cannot map to that customer. This is especially important if you are merging customers and orders between sites and you want your customers to keep their same password.
What plugins do we need to do this?
Below are the following plugins to use in your migration:
Yes, I know these are paid plugins but I tried a lot of free and other paid plugins and was not able to successfully migrate my orders without the two plugins above.
Not only will these plugins save you a lot of time and headaches in the migration process, but will also ensure that your customers and orders are moved correctly.
1. Export Customers from Site A
First, go to Site A and upload and activate the Customer / Order CSV Export plugin.
Next, on your WordPress dashboard, hover over WooCommerce and click “CSV Export”.
Then, go to Settings, toggle Customers, and select the dropdown to CSV Import and click “Save Settings”.
Finally, go to CSV Export tab, toggle Customers and click “Export”.
When the export is completed, navigate to the “Export list” tab, and download your CSV file.
My exports freeze without completing. How do I fix this? If you exports freeze without completing, ensure that your site is not blocking HTTP requests.
Before proceeding to part 2, do a quick check of your customers CSV file.
The first 3 columns should be username, email, and password.
If the first 3 columns are customer_id, first_name, and last_name you did not export your customers from Site A using the “CSV Import” export format method (reminder, we completed this in step 3 above).
customer_id first_name last_name
Here is a sample CSV file if you want to be certain you are following the directions: sample customers csv import
If your CSV file is correct get ready to import your customers from Site A to Site B in part 2!
2. Import Customers from Site A to Site B
First, go Site B and upload and activate the Customer / Order / Coupon CSV Import Suite plugin.
Next, on your WordPress dashboard hover over WooCommerce > click “CSV Import Suite”.
Then, click “Import Customers”, upload your customers CSV file, and click “Import”.
Finally, toggle settings based on the customers you import and click “Next”.
For example, if a customer does not have a shipping address set, I toggle to use their billing address. In addition, since we exported the customers using the CSV Import format in Part 1, the user passwords are correctly hashed and do not need to be re-hashed.
Pro tip: the first 3 columns of your CSV file should be username, email, and password.
After confirming your mapping is setup correctly, scroll down and click “Dry Run”.
Running as a “Dry Run” will allow you to see how the data is interpreted before running the import.
If you make a mistake, you can always restore to the previous backup point.
When everything is ready to go, click “Run a live import now”.
Congrats! You have migrated your customers from Site A to Site B.
In part 3, we will be exporting your orders from Site A.
3. Export Orders from Site A
Before exporting your orders from Site A, ensure that the SKUs on each product (and product variation if any) on Site A match the products on Site B.
First, go back to Site A. On your WordPress dashboard, hover over WooCommerce and click “CSV Export”.
Are you only importing/exporting WooCommerce orders? If you have not done so already, the first step is to purchase, download and activate the Customer / Order CSV Export plugin on Site A.
Next, go to the Settings tab, toggle Orders, and select the dropdown to “CSV Import” and click “Save Settings”.
Then, click the “Export” tab, ensure the export is toggled to Orders and click the Export button.
Finally, when the export is done, click the “Export list” tab and download the exported Orders CSV file.
In part 4, we will be importing orders from Site A into Site B.
4. Import Orders from Site A to Site B
Before importing your orders, I would highly recommend taking a backup of Site B!
In addition, download and activate the Disable Emails free plugin. This plugin stops emails from sending on your WordPress server. This is beneficial when you import the orders to Site B as it blocks email notifications to send to your customers. I have made this mistake by not utilizing this plugin and have have sent over 5,000 order notification emails to past customers from orders 5 years ago!
Are you only importing/exporting WooCommerce orders? If you have not done so already, purchase, download and activate the Customer / Order CSV Import Suite plugin on Site B.
First, navigate to Site B and on your WordPress dashboard hover over WooCommerce, click “CSV Import Suite”.
Then click “Import Orders”.
Next, upload your Orders CSV file, click “Next” and configure the options.
When finished, click “Next”.
Pro tip: If your product SKUs have changed and want to import products with an updated SKU, open up your Orders CSV file, and run a search and replace on the product SKUs that have been updated before importing your orders.
Then, make sure your Orders CSV file is mapped properly.
Even if you’re not merging orders, skip the first column “id” in the file mapping.
The first 3 columns imported should be:
When finished, click “Next”.
Finally, click run as a “Dry Run” and if everything went smoothly, click “Run a live import now”.
Congratulations! You have migrated your orders and customers from Site A to Site B!
Pro tip: make sure to deactivate the Disable Emails plugin after completing the migration process. You want new orders to be able to receive email confirmations!
Migrate Customers and Orders (Example #1)
Migrate Customers and Orders (Example #2)
How to Export Customers?
How to Import Customers?
Frequently Asked Questions
How do I keep my order numbers the same during migration?
If you want your migrated orders to keep the same order number for each order, download the Sequential Order Numbers plugin (free) plugin or Sequential Order Numbers Pro plugin (paid) plugin on Site A before exporting your Orders and Site B before importing your Orders.
Every post on a WordPress site has a unique, auto-incremented post ID. This is also why your order numbers are not sequential by default: the order number typically equals order ID; this ID is pulling from a counter that’s also incremented each time a product, blog post, page, or other content is added.
Ensure the first and second columns are order_number and order_number_formatted and NOT IMPORTING the “id” column since this will be auto-incremented when importing to Site B.
My exports freeze without completing. How do I fix this?
If you exports freeze without completing, ensure that your site is not blocking HTTP requests. For example, if you are on a staging site and users have to enter a username and password before entering the site, disable this on your staging site server to allow exports to process.
Can I migrate one customer and one order before migrating everything at once?
Yes! A good way to minimize any trouble in migration is to export one customer, import one customer, export one order (belonging to that customer), and then importing that order. If everything went well during the single customer migration, I then migrate all customers and orders.
Single order import
If I have 10 or 100,000 orders to import, I always import a single order to minimize any trouble in migration.
Note: after the single order has been imported, navigate to WooCommerce > Orders > and study the single order to ensure everything migrated correctly.
All orders import
If the single order import went well, repeat the steps above and import all orders into your site.
How can I reformat my CSV file before importing my orders into Site B (Step 4)?
For example, you may want to update the status column of your Orders CSV file before importing. These orders may now have the orders status completed but previously were processing or on-hold. If any orders need to be updated from “on-hold” to “completed” or from “processing” to “completed”, do the following:
- Highlight Column D > click Edit > click Find and Replace.
- Find “on-hold”, replace all to “completed”.
- Find “processing”, replace all to “completed”.
After your CSV file is ready to go, go to File > Download As > Comma-separated values (.csv, current sheet).
How do I migrate orders for “guest” customers?
To export/import customers who created orders as a guest user, ensure the following 3 things are occurring in your customer and order CSV files:
1) Customers CSV file: if a guest customer, leave the “username” and “password” field blank. By default, if “username” is not provided, the order will be marked as a guest purchase.
2) Orders CSV file: if a guest customer, leave the “customer_user” field blank.
3) In WooCommerce > Settings > Accounts & Privacy, ensure that “Allow customers to place orders without an account” is checked.
I do not use a premium managed WordPress host such as WP Engine or Kinsta. How can I easily create a backup with a plugin?
If you are looking for a high quality WooCommerce hosting provider I would highly recommend Kinsta. I just switched our site to Kinsta and our site is a lot faster than it was on WP Engine. One of the reasons is that every site on the Kinsta platform runs in an isolated software container, meaning you don’t have to worry about your performance with other websites that are on the same server as you. Kinsta also has a great blog with a ton of WordPress and WooCommerce related resources.
How come you wouldn’t just copy the live site to the dev site? Wouldn’t all orders be migrated?
If you are developing an entirely new theme I prefer to start with a fresh WordPress install, develop the theme, and then re-import the products, customers, coupons, and then orders.
What would be a scenario where I would re-hash the user passwords when importing customers to Site B?
If you are importing customers that previously did not have account on WooCommerce, you would enable this option. Your CSV file for the “password” column would be plain text passwords that are not hashed.
For example, the password column would have passwords that look similar to “Holiday20” or “password123”.
How long will it take for my customers or customers to export or import to the list?
This can anywhere from 5 seconds to 30-45 minutes depending on how many customers and orders you are exporting or importing.
Do you have a tutorial on how to Migrate Shopify Orders & Customers to WooCommerce?
Yes, please see this blog post here: How to Migrate Shopify Customers and Orders to WooCommerce.
How do I migrate WooCommerce Subscriptions?
However, the CSV Export plugin will not export the “Subscriptions”. For example, after migrating your orders, your Subscriptions tab will be empty, even though you imported subscription parent and renewal orders.
To migrate Subscriptions (not parent or renewal orders associated with each subscription), I recommend using the WooCommerce Subscriptions Importer/Exporter extension.
- Docs: Customer / Order CSV Export
- Docs: Customer / Order CSV Import
- How To Migrate WooCommerce Products
- How To Migrate Shopify Customers and Orders to WooCommerce
Note: links in this post have affiliate links where applicable.