Below is a “menu” of proven ways to clone / keep-in-sync WooCommerce products between two WordPress stores and refresh the prices twice a day.
Pick the option that best matches your technical comfort level, hosting policy and budget.
0. Before You Start
| Checklist | Why it matters |
|---|
| ✅ Written permission (or same owner) to reuse the products | Copyright & TOS compliance |
| ✅ Access to source site (admin / REST API keys / SFTP) | Needed for feeds or API calls |
| ✅ Matching currency & tax rules | Avoid wrong price display |
| ✅ Unique product identifier (SKU is ideal) | Lets us match “same” product later |
| ✅ Backup of both sites | Roll-back safety net |
1. Quick-&-Easy: “No-Code” Plugin Route
-
On the SOURCE site
a. Install “Product Feed PRO for WooCommerce” (free) or “CTX Feed”.
b. Create a feed (CSV or XML) that contains at minimum:
• SKU / ID
• Name
• Regular Price / Sale Price
• Stock Qty (optional)
• Image URL(s) & Categories (optional)
c. Place the feed at an accessible URL (e.g. https://source.com/feed/products.csv).
d. Set Feed refresh interval to 30 minutes (plugin option); the file is regenerated automatically.
-
On the TARGET site
a. Install “WP All Import Pro” + “WooCommerce Add-On” + “Automatic Scheduling Add-On”.
b. Go to All Import → New Import → “Download from URL” and paste the feed URL.
c. Mapping screen:
• Unique Identifier: SKU
• Product Title ↔ Title, Description ↔ Description, etc.
• Price: map “regular_price”.
• Tell importer to “Update existing products, create new ones, and SKIP product deletion”.
d. In “Scheduling” choose Twice Daily (every 12 h) or set exact cron times such as 0 3 * * * and 0 15 * * *.
e. Save & run the first import manually.
-
Advantages / Disadvantages
| 👍 Pros | 👎 Cons |
|---|
| 100 % no-code, GUI driven | Paid plugin (≈ $149 one-off) |
| Handles variable products & images | Slightly heavy on large catalogs |
| Reliable logs & email alerts | You still host the image files yourself |
2. All-in-One Sync Plugin (When You Control Both Stores)
Plugin examples:
• “WooCommerce API Product Sync with Multiple WooCommerce Stores” (Codecanyon)
• “Woomultistore”, “StorePep Multi-Store Sync”, etc.
How it works
• Install on both sites, enter the REST API keys of each other, choose Pull or Push.
• Tick which data to sync (Price only, Stock only, All).
• Built-in scheduler where you pick twice-daily.
Pros
• One-click bidirectional sync, even orders & stock if needed.
Cons
• Requires admin access to source site.
• Commercial (~ $49–99).
• Less granular control compared with custom code.
3. DIY Developer Route (REST API + Cron)
Good if you don’t want extra plugins or need full control.
3.1. High-level Flow
- Target site cron fires at 03:00 & 15:00 server time.
- PHP script calls Source-Store REST API:
GET https://source.com/wp-json/wc/v3/products?per_page=100&modified_after=...
- Loop through response:
• If SKU exists → update price & whatever fields you need.
• If SKU does not exist → create product.
- Handle variations (second request to
/products/<id>/variations).
- Save log file + email on failure.
3.2. Sample Code (simplified)
Add to target site’s must-use plugin (or custom plugin):
<?php
/*
Plugin Name: Source->Target WC Price Sync
*/
// Run every 12 h
register_activation_hook(__FILE__, function () {
if (! wp_next_scheduled('wc_price_sync_event')) {
wp_schedule_event(time(), 'twicedaily', 'wc_price_sync_event');
}
});
register_deactivation_hook(__FILE__, function () {
wp_clear_scheduled_hook('wc_price_sync_event');
});
add_action('wc_price_sync_event', 'sync_prices_from_source');
function sync_prices_from_source() {
// 1. Credentials
$src_url = 'https://source.com/wp-json/wc/v3/products';
$ck = 'ck_xxxxxxxxxxxxxxxxx';
$cs = 'cs_xxxxxxxxxxxxxxxxx';
// 2. Pull products (paginated)
$page = 1;
do {
$response = wp_remote_get( add_query_arg([
'per_page' => 100,
'page' => $page,
'fields' => 'id,name,sku,regular_price,sale_price',
], $src_url ), [
'auth' => [$ck, $cs] // Basic Auth, or use oauth1
] );
$products = json_decode( wp_remote_retrieve_body( $response ), true );
foreach ( $products as $p ) {
if ( empty($p['sku']) ) continue; // need SKU
$id = wc_get_product_id_by_sku( $p['sku'] );
if ( $id ) {
// Update existing
update_post_meta( $id, '_regular_price', $p['regular_price'] );
update_post_meta( $id, '_sale_price', $p['sale_price'] );
wc_get_product($id)->set_price($p['sale_price'] ?: $p['regular_price']);
} else {
// Optional: create new product
$new = new WC_Product_Simple();
$new->set_name( $p['name'] );
$new->set_sku( $p['sku'] );
$new->set_regular_price( $p['regular_price'] );
$new->set_sale_price( $p['sale_price'] );
$new->save();
}
}
$page ++;
} while( count($products) === 100 );
}
Notes
• Store the keys ($ck, $cs) in wp-config.php or environment variables for security.
• To sideload images use media_sideload_image() once per product (images rarely change, so run on first import only).
• When the catalog is huge (>10 k) add “modified_after” to fetch only deltas.
3.3. Cron Reliability
WP-Cron is hit-or-miss on low-traffic sites. If possible, disable WP-Cron and create a real server cron:
0 3,15 * * * wget -q -O - https://target.com/wp-cron.php?doing_wp_cron > /dev/null 2>&1
4. Extra Touches & Best Practices
| Topic | Tip |
|---|
| SEO duplication | Change product permalink or no-index pages if the two shops are public clones. |
| Currency rounding | If the source is € and target is $, apply a conversion formula inside import (“Price = regular_price * 1.07”) in WP All Import or via code. |
| Price margin | Add a % markup rule in the importer or script before updating. |
| Stock & images | You may map additional fields the same way; schedule them daily instead of twice a day to save bandwidth. |
| Error monitoring | Send wp_mail() with $response['response']['code'] if REST API != 200. |
| Cache flushing | After bulk price update call wc_delete_product_transients() or wp_cache_flush() so storefront shows new prices. |
| Staging first | Test on a staging copy before touching live catalog. |
5. Decision Matrix – Which Route Fits You?
| Need / Constraint | Best Choice |
|---|
| “I have zero coding skills, just want it to work” | Plugin route (#1) |
| “I own both stores & want order+stock sync” | Multi-Store Sync plugin (#2) |
| “I need total control or want to avoid paid plugins” | DIY REST API + Cron (#3) |
| “Source refuses plugins, but will give me API keys” | DIY (#3) |
6. TL;DR Implementation Plan (Commonest Scenario)
- Get SKU-based XML/CSV feed from source (many owners happily provide it).
- Use WP All Import + Scheduler on your site, run at 03:00 & 15:00.
- Map price fields, tick “update existing products”.
- Add 10 % markup rule if required.
- Monitor mails/logs for failed runs.
- Enjoy auto-updated prices 🎉
Feel free to ask for deeper dives (variable products, images, currency conversion, etc.) and I’ll expand with exact field mapping or code snippets.