Back to blog
5 min read WooCommerce

Export WooCommerce Shipping Zones and Copy Them to Another Store

WooCommerce has no button to export shipping zones. A store with zones for Germany, Austria and Switzerland, a US zone limited by postcode, free shipping above 60 EUR and an extra fee for bulky items has to be clicked together again on every new site: each zone, each region, each method and each shipping class cost. Import Export by RockStarLab PRO exports the zones to a CSV file and imports them on the other store with their regions, methods and costs.

PRO: shipping zones are part of the PRO plugin. Tested with Import Export by RockStarLab 2.2.14 and PRO 2.1.32, WooCommerce 11.2, WordPress 7.1.

Short Answer

On the source store, open Import Export by RockStarLab > Export, choose WooCommerce Shipping Zones, add all columns and export a CSV. On the target store, import the file as WooCommerce Shipping Zones with Zone Name as the match field. Existing zones with the same name are updated, new ones are created.

What the File Contains

Each zone is one row. The “Locations not covered by your other zones” zone (Rest of the world in the WooCommerce screen) is the last row, with zone ID 0.

Column Example
zone_name DACH test
zone_order 1
zone_locations country:DE, country:AT, country:CH
shipping_methods JSON with each method, its title, enabled state, order and settings
shipping_methods_summary Standard (DHL) (cost 4.90); Free shipping (minimum order 60); Pick up at the roastery [disabled]

Regions are written as country:DE, state:US:CA, postcode:90210 or continent:EU. When you edit the file by hand, a bare DE counts as a country and US:CA as a state.

WooCommerce stores shipping class costs under the class ID, for example class_cost_22871. That ID belongs to one site only, so the export writes the class slug instead (class_cost:bulky) and adds the class name. The import looks up the class with that slug on the target store and creates it when it is missing.

Step 1: Export the Zones

Open Import Export by RockStarLab > Export and choose WooCommerce Shipping Zones:

Export screen with the WooCommerce Shipping Zones card selected
Choose WooCommerce Shipping Zones on the Export screen.

The Filters step shows how many zones the store has; our test store had 3. On the Fields step, add Zone ID, Zone Name, Zone Order, Zone Regions and Shipping Methods JSON. The summary column is for reading the file in a spreadsheet; the import ignores it. Choose CSV on the Format step and run the export.

Step 2: Import on the Other Store

Back up the target store’s database first. The import replaces the methods of every zone it matches, and a zone deleted by mistake has to be rebuilt by hand.

Open Import Export by RockStarLab > Import, choose WooCommerce Shipping Zones and upload the file. Auto Map assigns the five columns:

Import mapping: zone_id, zone_name, zone_order, zone_locations and shipping_methods mapped to the same fields
Auto Map assigns the five zone columns.

On the Options step, Check for Existing Items by Field is set to Zone Name. Keep it: zone IDs differ between stores, so matching by ID would update the wrong zone. With If Match Found set to Update, running the same file twice changes nothing; the methods are replaced, not added a second time.

The import of our file reported 3 updated zones, and the WooCommerce shipping screen of the target store showed the same regions and methods as the source:

WooCommerce shipping zones after the import: DACH test with Germany, Austria, Switzerland, USA with United States and postcode 90210, Rest of the world with International
The target store after the import.

The disabled local pickup method stayed disabled and the methods kept their order. The flat rate got the bulky class cost of 12.00 under the new store’s class ID.

Only Change the Regions

Leave the shipping_methods cell empty to keep a zone’s methods as they are. A file with only zone_name and zone_locations moves a zone to new regions, for example from country:US, postcode:90210 to US, CA:ON (the United States and Ontario), and leaves its rates alone.

Shipping Classes of the Products

The zones file carries the shipping class costs. Which products belong to which class is part of each product, so export the products with the Shipping Class column and import that file on the other store too; both files come from the same plugin.

With WP-CLI or an AI Agent

The whole move is two WP-CLI commands, one on each store:

wp rsl-ie export --type=shipping-zone --name=zones --user=admin
wp rsl-ie import zones.csv --type=shipping-zone --user=admin

We ran them with Import Export by RockStarLab 2.2.64 and PRO 2.1.57. Export job 484 wrote the zone “Germany (CLI test)” with its country DE, a flat rate “Standard” of 4.90 and “Free shipping” from 50, plus the zone for locations not covered. Import job 93611 on the other store created the zone with the same region and both methods, with the same costs and the minimum amount.

An AI agent connected through the WordPress MCP Adapter does the same from a request. Without the plugin, WordPress 7.1.5 gives the agent only three read-only abilities for site, user and environment information, so it cannot read or create shipping zones. The export and import of zones are abilities of the plugin:

With Import Export by RockStarLab, export the shipping zones of this store with their regions and methods to CSV, then import the file into the live store.

WP-CLI

wp rsl-ie export --type=shipping-zone --format=csv --user=admin
wp rsl-ie import shipping-zones.csv --type=shipping-zone --user=admin

FAQ

Can I export WooCommerce shipping zones?

Not with WooCommerce alone. Import Export by RockStarLab PRO exports them to CSV, Excel, JSON or XML with regions, methods, costs and shipping class costs.

Are shipping class costs kept when the class IDs differ?

Yes. The file refers to the class slug, and the import uses the target store’s class with that slug or creates it.

Does the import create duplicate zones or methods?

No, when zones are matched by name. A matched zone gets its methods replaced by the ones in the file.

Is the Rest of the world zone included?

Yes, as zone ID 0 in the last row. Its methods are imported into the target store’s Rest of the world zone.

Get the free plugin on WordPress.org. Shipping zones are part of PRO.

Dmitriy
About author

Dmitriy

WordPress Developer with 15+ years of commercial experience. Elite Author on ThemeForest and creator of custom WordPress plugins. Passionate about clean code, performance optimization, and building useful tools for the WordPress community.

JOIN THE CONVERSATION

Comments 0

Have a question or a tip to share? Leave it below.

Leave a comment

Your email address will not be published. Required fields are marked *

We store your name, email and comment to show and moderate it; your email is never published. Spam protection is provided by Cloudflare Turnstile and profile pictures by Gravatar. See our Privacy Policy.


Try the plugin with no risks!

New users get 1 month with access to all premium features. Experience the most powerful WordPress data engine today.

Download Now
Get PRO for FREE