WooCommerce WebP Image Optimizer
Convert png/jpg to Webp With balk images
by Garib Sons · github.com/suneeb-k/webp-image-optimizer · website
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/suneeb-k/webp-image-optimizer/archive/refs/heads/main.zipConvert WordPress and WooCommerce media images to WebP, replace originals, update metadata and database URLs, with batch resume and WP-CLI.
Description
WooCommerce WebP Image Optimizer converts JPG/JPEG/PNG media library images to WebP and fully replaces the originals so WordPress treats WebP as the source files.
Built for large catalogs (hundreds of products, multi-GB uploads) with memory-efficient batch processing and resume support.
Features
- Converts original images and every generated size (thumbnail, medium, large, WooCommerce sizes, custom sizes)
- Uses Imagick when available, otherwise GD
- Quality 80% by default — no resizing
- Updates attachment metadata and MIME types
- Serialized-safe database URL replacement (posts, meta, options, ACF, Elementor, WooCommerce galleries)
- Deletes originals only after WebP verification
- Batch processing (default 20) with pause / resume / stop
- WP-Cron and Action Scheduler support
- Auto-convert newly uploaded images
- Image List tab for single-image test conversion
- WP-CLI:
wp webp convert|resume|retry|status - Dry run, backup mode, orphan cleanup, CSV report export
- Logging to
uploads/webp-converter/log.txt
Requirements
- WordPress 6.x
- PHP 8.2+
- Imagick with WebP or GD with
imagewebp() - WooCommerce recommended (not strictly required for media conversion)
Installation
- Upload the
woocommerce-webp-image-optimizerfolder to/wp-content/plugins/ - Activate the plugin through the Plugins screen
- Go to Media → WebP Optimizer
- Review Settings, then use Dashboard to start conversion or Image List to test a single image
Frequently Asked Questions
Will originals be deleted?
Only when Delete Originals is enabled and the WebP file passes verification (exists, readable, size > 0, metadata updated). On failure, originals are kept.
Can I resume after a timeout or deactivation?
Yes. Progress is stored in the database. Use Resume in the admin UI or wp webp resume.
Does this corrupt serialized data?
No. The URL replacer unserializes (or length-corrects) PHP serialized values and also handles JSON where needed.
How do I convert via CLI?
wp webp convert wp webp convert --id=123 wp webp resume wp webp retry wp webp status
Changelog
1.0.0
- Initial release: batch conversion, admin UI, Image List, CLI, auto-upload convert, orphan cleanup, CSV reports.
Upgrade Notice
1.0.0
Initial release.