
"Small Images Compressor and Modernizer" - Local AVIF/WebP Compression for WordPress Sites Tired of Renting What Their Server Already Does
In an era where image optimization quietly became a rented service - an API key, a credit meter, a plan tier, a monthly invoice - I built Small Images Compressor and Modernizer as the deliberate opposite: a free, lightweight WordPress plugin (~75 KB, 14 files) that compresses images and generates WebP and AVIF versions locally, using nothing but PHP's Imagick or GD on your own server. It was built for one simple reason: I was paying for a subscription whose usage ceiling I never approached, while barely using a couple of thousand API calls a month. The maths stopped making sense, so I removed the meter.
The Rented Pipeline Problem
Image optimization as a category drifted from utility to middleware. The typical setup wraps a hosted API: your media leaves your server, gets processed somewhere else, and comes back credit by credit - and the moment you stop paying, the pipeline stops. Even when the heavy lifting is trivially within reach of the machine you already rent every month.
Because here is the thing nobody in the marketing copy says out loud: PHP's own imaging libraries already speak AVIF and WebP. Your server can compress an image, convert it to a modern format, and serve it to the right browser - all on hardware you are already paying for. The dominant workflow routes that work through someone else's API or CDN, bills it per image or per call, and adds a dependency your site did not need. My actual situation never justified any of that: a handful of sites, a few thousand images, and a monthly charge sized for somebody else's media library. So the specification for this plugin was written backwards from that reality. Instead of asking "what can the service do?", the question was "what can the server do by itself?" The answer turned out to be: everything I was renting.
"Nothing Leaves Your Server"
The plugin promises this in plain text, and the architecture keeps the promise. There is no API key, no account, no credits and no monthly subscription, because there is no remote service to authenticate against. Compression happens locally through Imagick or GD. The WebP and AVIF files are saved next to your originals as photo.jpg.webp and photo.jpg.avif, and delivery to browsers is handled on-site through <picture> markup and an .htaccess rule serving with Vary: Accept. Your originals can optionally be backed up on your own server, in wp-content/uploads/sicm-backups/. Deactivate the plugin and your site keeps working - it was never the plugin's property to begin with.
What It Does
On activation, it lives under Media → Image Modernizer. It compresses images and generates WebP and AVIF variants, serves them through <picture> with the right fallbacks, and keeps an escape hatch via the sicm-skip class for images you do not want touched. Bulk optimization can run from the admin interface, but for existing libraries - and anywhere you have SSH - WP-CLI is faster and immune to browser and PHP timeouts:
wp sicm optimize --all
It is safe to stop and re-run; already-optimized images are skipped. Coming from another optimizer, the migration is deliberately boring: deactivate the old plugin, activate this one, run wp sicm optimize --all - images that were already compressed are kept as they are when re-compression would not make them smaller. wp sicm restore --all restores your untouched originals whenever you want out, and uninstalling removes settings and records but never deletes image files.
Honest Limits, Because Over-Promising Is the Real Bloat
This plugin is not a CDN, not an on-the-fly transformer, and not a magic zero-configuration appliance - which is precisely the point. AVIF needs PHP 8.1+ GD built with AVIF, or Imagick built with libheif/libavif - check Media → Image Modernizer → Server & delivery or wp sicm env; without it, the plugin still produces WebP. Background processing depends on WP-Cron: with the default "process in the background" setting, an upload is optimized roughly 5-30 seconds later, and if your host sets DISABLE_WP_CRON, a real cron job has to trigger wp-cron.php or uploads sit queued. Backups plus the .webp/.avif siblings mean your uploads directory can grow around 1.5-2× during the first run - plan for it, or turn backups off if you already keep your own. On a large library, use the WP-CLI route. It is a compressor for someone who owns their server and would like their optimizer to do the same.
Vibe-Coded, Declared Openly
The plugin was built with Claude (Anthropic) writing a great deal of the code; I directed the product decisions, the scope discipline and the refusal to bolt on a service tier. Saying that plainly is part of the point - the interesting engineering here was not typing speed, it was deciding that an image compressor should stop being a business relationship and go back to being a utility.
The result is released as free software under the GNU General Public License, version 3 or later, copyright © 2026 Marko Idžan, provided without warranty. Source, issues and releases are public on GitHub.
Get It
Download the repository, upload dist/small-images-compressor-modernizer.zip via WP Admin → Plugins → Add New → Upload Plugin, activate, and open Media → Image Modernizer. Then delete the image-optimizer line item from your hosting bill - it was costing more than the problem it solved.
Links: GitHub repository - github.com/idzanhr/smallpix_avif_webp_compressor_wordpress · License: GPL-3.0-or-later