Overview
Optimole describes itself as: “Automatically optimize images with bulk compression, lazy loading, WebP/AVIF conversion & CloudFront image CDN. Boost Core Web Vitals & conversions.”
It is active on 200,000+ WordPress sites and rated 4.7 out of 5 by 641 users on WordPress.org. Developers can extend it through 18 actions and 62 filters, listed below.
How to install Optimole
- Open the plugin installer. In your WordPress dashboard go to Plugins → Add New Plugin.
- Search for it. Type “Optimole” and pick the one by Optimole.
- Install and activate. Click Install Now, then Activate.
Install with a zip file or WP-CLI
Download the zip from the WordPress.org plugin page, then go to Plugins → Add New Plugin → Upload Plugin, choose the file and click Install Now. Or from the command line:
wp plugin install optimole-wp --activateRequirements: WordPress 5.5+ · PHP 7.4+ · tested up to WordPress 7.1.4
Hooks & customisation
Optimole 4.2.20 fires 18 actions and 62 filters. Use them from your child theme or a snippets plugin to change how it behaves without editing its files.
// Clear cache when storing profile data.
do_action( 'optml_clear_cache', $current_url );
// The current date.
apply_filters( 'themeisle_sdk_current_date', new \DateTime( 'now' ) );
// Action triggered after the attachment file is renamed.
do_action( 'optml_after_attachment_url_replace', $this->attachment_id, $old_url, $new_url );
// Filters whether the page is captured and processed at shutdown, outside of PHP…
apply_filters( 'optml_capture_at_shutdown', false );
// Filters the captured page HTML before Optimole processes it.
apply_filters( 'optml_captured_page_html', $html );
// Filters whether Optimole leaves an image's existing sizes attribute unchanged.
apply_filters( 'optml_keep_existing_sizes', $keep, $tag );Need Optimole customised?
Tell us what you want changed, added or fixed and we'll reply with an estimate.
WP EXPERTS is independent and not affiliated with Optimole. Plugin names and logos belong to their owners. Version, rating and install figures from WordPress.org, checked Nov 17, 2026.