Pixellize Image Optimizer

A free WordPress plugin that automatically converts uploaded images to WebP, so your pages load faster and use less bandwidth.

Everything happens on your own server using PHP GD or Imagick. There is no cloud account, no API key, and no paid tier. You upload images the way you always do, and the WebP version is ready immediately.

What this plugin gives you
  • Automatic WebP conversion for every new upload, including all thumbnail sizes
  • A Keep Original option, with a one-click Restore in the Media Library
  • Automatic cleanup of WebP files when you delete an image
  • A simple settings page with a savings panel

Requirements

  • WordPress 5.0 or higher (tested up to 7.0)
  • PHP 7.4 or higher
  • PHP GD extension or Imagick extension (most hosts have at least one)

The plugin checks for GD or Imagick on activation. If neither is available it will not activate, and an admin notice tells you what is missing.

Installation

  1. In your WordPress admin, go to Plugins then Add New.
  2. Search for Pixellize Image Optimizer.
  3. Click Install Now, then Activate.

Manual upload

  1. Download the plugin ZIP from wordpress.org.
  2. Go to Plugins then Add New then Upload Plugin.
  3. Choose the ZIP, install, and activate.

Quick start

  1. Install and activate the plugin.
  2. (Optional) Go to Tools then Pixellize Image Optimizer to review settings.
  3. Upload images the way you always do.

WebP versions are generated automatically. That is the whole setup.

Settings

All settings live at Tools > Pixellize Image Optimizer.

Image formats to convert

Choose which uploaded formats should be converted to WebP.

  • JPG / JPEG and PNG are on by default.
  • BMP and AVIF are off by default. Turn them on if you upload those formats.

WebP quality

A slider from 0 to 100. Default is 85.

  • 80 to 90 gives the best balance of file size and visual quality.
  • Values below 60 can show visible artifacts on detailed photos.

Keep original image

A toggle. Off by default.

  • Off: the upload is replaced by a WebP and the original is deleted to save space.
  • On: the original stays in your Media Library and a WebP is built for the full image and every thumbnail size. You can restore any image back to its original.

How it works

On upload

When you add an image to your Media Library, the plugin generates a WebP version.

  • If Keep Original is off: the upload is replaced by a single WebP and the original is removed.
  • If Keep Original is on: the original stays put and a WebP copy is created for the full image and every thumbnail size, so responsive markup is fully covered.

On the front end

The plugin swaps image URLs to the WebP version in the right places:

  • Theme image tags (the standard WordPress attachment image)
  • The responsive srcset attribute
  • Image URLs inside post content
  • The Media Library preview and details

If a WebP is not available for a given file, the original is served instead. Nothing breaks.

If a conversion fails

The original is left untouched and an admin notice appears on the next page load with the file name, MIME type, and a clear reason. Nothing is silently dropped.

Keep Original mode

The default behavior replaces every upload with a single WebP to save disk space. Turn on Keep original image in the settings if you want to:

  • Keep your source files in the Media Library
  • Be able to restore any image back to its original later
  • Offer downloads of original files

With this option on, both formats sit on disk side by side. Visitors are served the lighter WebP automatically, and you keep the originals safe for whenever you need them.

Restore an image

With Keep Original turned on, a Restore original link appears in the Media Library row actions for any WebP attachment that has its original on disk.

Clicking it:

  1. Points the attachment back at the original file.
  2. Rebuilds all of its sizes from the original.
  3. Removes the WebP copies that are no longer needed.

This is the safe way to roll a single image back without touching anything else.

Statistics

The settings page includes a savings panel that shows:

  • Number of images converted
  • Total original size
  • Total WebP size
  • Total saved (in bytes and as a percentage)

Use the Reset statistics button to clear the counters and start tracking from zero.

Supported formats

FormatDefaultNotes
JPG / JPEGOnBest fit for photos.
PNGOnWorks for transparent and non-transparent PNGs.
BMPOffTurn on in settings if you upload BMP files.
AVIFOffNeeds a server with AVIF read support in GD or Imagick. Best on PHP 8.1+.
WebPSkippedAlready optimized, so the plugin leaves it alone.

File naming

WebP files mirror the original filename, so the Media Library stays predictable:

  • photo.jpg becomes photo.webp
  • photo-300x200.jpg becomes photo-300x200.webp

If you upload a second image with the same name, WordPress renames the upload to photo-1.jpg as usual, and the WebP follows: photo-1.webp.

FAQ

Does it convert images already in my library?
Not in version 0.4. The plugin converts new uploads. Bulk conversion of existing images is the next major feature on the roadmap.
Is the original image deleted?
By default yes, the upload is replaced by a WebP to save space and the original is removed after a successful conversion. Turn on Keep Original to keep the source file in your Media Library and enable restoring an image to it later.
Can I get an image back to its original?
Yes, when Keep Original is on. A Restore link appears in the Media Library row actions for any WebP attachment that has its original on disk.
What if my server does not support GD?
The plugin automatically falls back to Imagick. If neither is available, activation is blocked with a clear admin notice.
Can I control image quality?
Yes. Set WebP quality from 0 to 100. The default is 85, which works for most sites.
What happens if I upload a WebP file?
It is skipped. No re-encoding, no duplicate file, and no extra work for your server.
Does it work with my cache or CDN?
Yes. The plugin rewrites image URLs on the server side, which then get cached or served by your CDN like any other URL. Clear your cache after enabling the plugin so old image URLs are refreshed.

Troubleshooting

The plugin will not activate

This usually means neither PHP GD nor Imagick is installed on your server. Ask your host to enable one. Most modern hosts support both.

A specific image failed to convert

The plugin shows an admin notice on the next page load with the file name, MIME type, and a clear reason (for example, a corrupt source file or missing AVIF support). The original file is left untouched so nothing is lost.

My old images are not WebP

Only new uploads are converted in the current release. Re-upload the image or wait for the upcoming bulk conversion feature.

AVIF uploads fail

AVIF reading needs a server where GD or Imagick is built with AVIF support. Some hosts do not include that yet. PHP 8.1 or higher with a recent libavif is the most reliable combination.

Images look soft after conversion

Quality may be set too low. Raise it to 85 or higher in the settings and re-upload the image.

Changelog

0.4

  • New Keep Original mode that keeps your source files alongside the WebP for every size.
  • New Restore original action in the Media Library for one-click rollback.
  • Originals and WebP copies are cleaned up together when you delete an image, so no files are left orphaned on disk.
  • WebP is generated for the full image and every thumbnail size, so responsive markup is fully covered.
  • Cleaner WebP file names that mirror the original (image.jpg becomes image.webp).
  • Redesigned settings page with a savings panel.

0.3

  • Tested with WordPress 7.
  • WordPress Coding Standards compliance, documented intentional uses of low-level file operations and direct database counter updates.
  • Improved error logging for anonymous upload failures (gated behind WP_DEBUG).

0.2

  • Admin notices on conversion failure with file name, MIME type, and a clear reason.
  • Per-user failure log of the last 10 events, shown on the next admin page load.
  • Unique WebP filenames when a same-name image already exists.
  • Statistics panel and Reset Statistics button on the settings page.
  • Atomic SQL increments for stats, so concurrent uploads no longer drop counts.
  • Clean uninstall that removes all plugin options and per-user data.

0.1

  • Initial release.
  • Auto WebP conversion for JPG, PNG, BMP, and AVIF.
  • GD with Imagick fallback.
  • Quality control and format selection settings.
  • URL replacement across the site.

Support

Need help or want to share feedback?

The plugin is free and open source under the GPL v2 or later license.

Scroll to Top