Plugin Directory

Test out the new Plugin Directory and let us know what you think.
!This plugin hasn’t been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

Image Cleanup

Image Cleanup will index unreferenced images. These can be leftovers from cropping and scaling images. Stop them cluttering your content folder!

Did you ever scale or crop uploaded images in wordpress? Did you ever try various image generating plugins? Did you ever change or add various media image sizes? If yes, chances are that your content folder is full of unused and unreferenced images. These image leftovers will remain cluttering your content folder until the end of days.

Image Cleanup will index these (and many more) unreferenced images. Unreferenced images are not indexed in the wordpress database and also not used by posts, scripts or backup restore meta data. Please note that images which have valid database metadata but are not used in posts are not indexed at this time. This is beyond the scope of this plugin.

Image Cleanup will also find images without meta data and images with incorrect meta data.

  • Save space taken up by unreferenced/backup images!
  • Fix incorrect metadata (sizes)
  • Bulk repair/delete functionality
  • Pagination for extremely large result sets
  • Logs tabs easily visible for reviewing!
  • Detailed information in log tabs!
  • Full restore functionality!
  • Especially useful for developers!
  • Written as class to avoid any conflicts!
  • Highly configurable to avoid memory and/or timeouts on some setups

On my one month old website with 50 files (and 250 attachment size variants) this plugin found 95 unreferenced images which I could remove without any conflicts.

There has been a reported case where this plugin indexed and removed over 23.000 images on a website. See forum/review for details

Image Cleanup workflow details

  • Retrieves all attachment images from the database (including size variants);
  • Finds all images in the wp-content folder;
  • Subtracts the attachment (and size variants) from physical found images;

The above will result in an list of invalid images which are not referenced by the database

  • Posts will be searched for images and found images will be subtracted from the invalid files (if any);
  • Scripts in wp-content will be searched for images and they will be subtracted from the invalid files (if any);
  • Backup images (for restoring images after scale/crop) will be subtracted from the invalid images;
  • Found unreferenced files will be checked against the meta data to see if the database meta entry still exist;

This results in various image lists in which the images can be reviewed, repaired or removed.

After indexing

After indexing you are able to (temporary) move the images to a backup folder to check the site without the images in the wp-content folder. You could also check the logs in the ../wp-content/uploads/image-cleanup/ID/logs folder for full information about the index.

If any problems are found you can revert the move of images by restoring them to their original locations.

When no problems arrise after moving the images to another location it is possible to permanently remove the images.

Future planned additions

  • Index unused valid images
  • Index missing image sizes (and option to generate missing images)
  • Index missing images which are used in posts
Tags: , ,

Requires: 3.0.1 or higher
Compatible up to: 3.8.17
Last Updated: 3 years ago
Active Installs: 10,000+


3.5 out of 5 stars


0 of 2 support threads in the last two months have been marked resolved.

Got something to say? Need help?


Not enough data

0 people say it works.
0 people say it's broken.

100,1,1 100,1,1