Guide4 min readBy Metrotechs

Image Preservation Best Practices

Product images are often the most labor-intensive part of an e-commerce catalog. They've been photographed, edited, and optimized. Losing them during a migration or re-sync is unacceptable. Image preservation has been a core feature since v1.2.0, and here's how it works.

The Core Principle: Never Delete Existing Images

When Ecwid2Woo encounters a product that already exists in WooCommerce, it does not delete or replace existing images. If the product already has a featured image set, the plugin leaves it in place. This protects against scenarios where you've manually improved product images after the initial import. Safe re-syncing through idempotent operations prevents data corruption.

Source URL Tracking

Each imported image is tracked via custom meta fields that store the original Ecwid CDN URL. During subsequent syncs, the plugin compares the current Ecwid image URL against the stored source URL. If they match, the image is skipped entirely — no re-download occurs. This uses the timestamp comparison system that compares Ecwid update dates with local import records.

Gallery and Variation Images

Product galleries follow the same logic. Each gallery image's source URL is stored, and only new or changed images are downloaded during re-syncs. This prevents duplicate gallery images from accumulating over multiple sync operations. Variation-specific images are also supported — if Ecwid combinations have associated images, these are downloaded and set as the variation's featured image.

Category Thumbnails

The plugin also imports category images and attaches them to WooCommerce terms. Category thumbnails follow the same preservation logic, so they won't be re-downloaded on subsequent syncs if they haven't changed.

Best Practices

Run your initial sync to import all products and images. After the import, if you want to manually replace specific product images in WooCommerce, go ahead — the plugin won't overwrite your manual changes on subsequent syncs. Always backup your database before running large operations, and consider running the initial sync during off-peak hours for stores with very large image counts.

If you encounter any issues with images, enable WordPress debug logging (WP_DEBUG) to see detailed logs of every image decision the plugin makes during sync.

All Posts