Skip to content
WordPress plugin for regenerating thumbnails of uploaded images. Over 1 million active users and counting.
Branch: master
Clone or download
Latest commit 736df85 Jan 5, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
.wordpress-org Rename the "assets" folder to ".wordpress-org". Props WooCommerce Jan 3, 2019
css Animate the progress bar's progress via CSS. Oct 20, 2017
includes Filter the output of the only-missing-thumbnails filter function. Jan 3, 2019
js Move api-request.min.js to a js folder. Seemed wrong in includes. Nov 18, 2017
src Localization: Disambiguate "Regenerate Thumbnails" string. Fixes #82. Jan 4, 2019
tests Roll master back to v3.0.2 to fix broken build / experiments. Jan 3, 2019
.babelrc Roll master back to v3.0.2 to fix broken build / experiments. Jan 3, 2019
.editorconfig Copy .editorconfig from WordPress core Oct 9, 2017
.gitignore Update dependencies Jan 19, 2018
.phpcs.xml.dist Rename PHPCS config file and move and remove an exclusion. Jan 4, 2019
.svnignore Reflect new phpcs.xml.dist name in .svnignore helper file Jan 4, 2019
.travis.yml Travis CI: WP 4.9 unit tests don't seem to like PHP 7.3+ either. Jan 4, 2019
LICENSE Create LICENSE Sep 19, 2017 yarn build now makes the dev copy, build-production for prod. Jan 3, 2019
browsersync-config.json Browsersync config tweaks. Oct 10, 2017
composer.json Update Composer dependencies Jan 4, 2019
composer.lock Update Composer dependencies Jan 4, 2019
package.json Bump plugin version in package.json and don't clean the yarn cache. Jan 4, 2019
phpunit.xml.dist Add dummy unit tests and Travis CI integration thanks to WP-CLI. See h… Jun 25, 2017
readme.txt Update changelog for v3.1.0 Jan 4, 2019
regenerate-thumbnails.php Add missing </em> tag. Props @lidialab. Fixes #81. Jan 4, 2019
webpack.config.js Roll master back to v3.0.2 to fix broken build / experiments. Jan 3, 2019
yarn.lock Roll master back to v3.0.2 to fix broken build / experiments. Jan 3, 2019

Regenerate Thumbnails

Travis CI Build Status WordPress Plugin Version WordPress Tested WordPress Plugin Downloads WordPress Plugin Rating

Regenerate Thumbnails is a WordPress plugin that will regenerate all thumbnail sizes for one or more images that have been uploaded to your WordPress Media Library.

This is useful for situations such as:

  • A new thumbnail size has been added and you want past uploads to have a thumbnail in that size.
  • You've changed the dimensions of an existing thumbnail size, for example via Settings → Media.
  • You've switched to a new WordPress theme that uses featured images of a different size.

It also offers the ability to delete old, unused thumbnails as well as update the content of posts to use the new thumbnail sizes.



If you have command line access to your server, I highly recommend using WP-CLI instead of this plugin as it's faster (no HTTP requests overhead) and can be run inside of a screen for those with many thumbnails. For details, see the documentation of its media regenerate command.

Jetpack's Photon Module

Jetpack is a plugin by Automattic, makers of It gives your self-hosted WordPress site some of the functionality that is available to sites.

The Photon module makes the images on your site be served from's global content delivery network (CDN) which should speed up the loading of images. Importantly though it can create thumbnails on the fly which means you'll never need to use this plugin.

I personally use Photon on my own website.

Disclaimer: I work for Automattic but I would recommend Photon even if I didn't.

Building The Plugin

The latest release can be downloaded from, but if you wish to build your own copy, here's how:

  1. Make sure you have Node.js installed.

  2. Clone this repository inside your plugins directory:

    $ git clone
    $ cd regenerate-thumbnails
  3. Install yarn package manager. It's like npm but better.

  4. Install the other dependencies:

  5. Build the plugin's JavaScript file in production mode:

    yarn build-production
  6. Activate the plugin and visit Tools → Regenerate Thumbnails.

Development Mode

If you're looking to make modifications to this plugin's Vue.js code, run the following command:

yarn watch

This will do the following things:

  • Automatically rebuild the build.js file whenever any of the source files change.
  • Put Vue.js in development mode which will allow you to use a browser extension to help with debugging.
  • Spawn a Browsersync server at http://localhost:3030/ that will load a proxied version of your development WordPress install that automatically refresh the page in your browser when changes are made to files. Also if you open the site in multiple browsers, it will sync your navigation and scrolling between them. By default, this assumes that your WordPress install lives at localhost. If this is not the case (for example you're using Varying Vagrant Vagrants), then edit browsersync-config.json.

Alternatively if you just want to manually build a development copy of the Javascript, then run this command:

yarn build

Unit Tests

To run the PHPUnit unit tests, first run the script from the bin directory. Then simply run phpunit from the plugin's root directory.

You can’t perform that action at this time.