Do you want to delete thumbnails in WordPress? If you are looking for a simple method, keep reading this article.
Images are vital for any website. They help us attract users and improve the website’s appearance. The problem is that when you update a new image, WordPress creates several thumbnails.
This means you can quickly end up having a vast media library that may slow down your site. That’s why in this guide, we’ll show you how to delete thumbnails in WordPress and clean up your media library.
Table of contents
Why Delete Old Thumbnails in WordPress?
Before learning different methods to remove thumbnails, let’s first understand why you should do so.
Every time you upload an image to the media library, WordPress generates several thumbnails to display the image in places like featured posts, sliders, and so on.
Additionally, some themes and plugins also require different image sizes. As a result, the Media Library can store numerous fields and occupy a significant amount of space on your server, which can also slow down your site.
Additionally, most hosting companies limit the number of files per cPanel account. For example, Bluehost limits accounts to 50,000 files.
So, all those extra images can not only affect user experience but also cost you more money if you have to upgrade your plan. That’s why it’s essential to manage your images smartly and delete old thumbnails from your WordPress site.
In summary, to keep the thumbnail count low, you can delete all unused images from the media library. This will help you:
- Keep your media library optimized
- Save server resources
- Keep your site running smoothly without affecting user experience
How to Delete Thumbnails in WordPress?
In this guide, we’ll show you 3 different methods to delete old thumbnails in WordPress:
- Manually
- From the WP-Admin
- With Plugins
All of these methods are very effective and easy to apply, so you can choose the one that best suits your skills.
1. Delete Thumbnails Manually (functions.php file)
If your theme registers custom image sizes, WordPress will generate thumbnails based on those dimensions.
A simple way to avoid creating unnecessary thumbnails is by editing the theme’s functions.php file. Although you won’t be required to perform any complex coding, we recommend this method for those who have some experience modifying the theme’s core files.
NOTE: As you will be modifying the theme’s core files, we recommend using a child theme and backing up your WordPress site to keep your data safe.
The first thing you need to do is go to your WordPress admin dashboard > Appearance > Theme Editor.

Then, select the functions.php file located under Theme Files on the right.

Then, you will see the functions.php file in the text editor.

If you look more closely at the code, you will see the custom image size register codes. For each thumbnail that it creates, it specifies the size.

All you need to do is deactivate the thumbnails you don’t want to generate. To do that, you need to add /* at the beginning and */ at the end of the thumbnails you wish to disable. For example, you can disable all of them as follows:

Another option is to comment on the lines of code you want to disable by adding // at the beginning of the code. This can be useful if you want to disable specific lines of code. However, to disable multiple thumbnails, it’s better to use the multi-line comment /* */.
Once you are satisfied with the changes, update the file. This way, you will avoid your theme from generating the thumbnails you disabled in the functions.php file.
If you also have plugins that create thumbnails, you can disable them in the same way. To do that, go to Plugins > Editor and select the plugin you want to edit. Then select the functions.php file and repeat the process.
2. Remove thumbnails from the WP-Admin Panel
If you’re not comfortable editing your theme’s and plugins’ core files, you can also delete thumbnails from the WordPress admin panel.
To do this, log in to your site and go to Settings > Media. You will see three custom image sizes:
- Small
- Medium
- Large

By default, WordPress specifies some values for each image size. When you upload an image to your media library, your server will automatically create thumbnails of that original image in these sizes. If you have many images, this can consume a significant amount of disk space.
If you are not planning to use any thumbnails, you can turn this feature off.
All you need to do is enter 0 in all the fields and save the changes.

Since you set the height and width to 0, WordPress won’t save multiple copies of the images you upload.
This is an excellent and effective method for reducing the number of thumbnails your site generates.
3. Delete WordPress thumbnails with Plugins
The third method for deleting thumbnails in WordPress is to use plugins. In this section, we’re going to show you two great plugins for this task:
- Media Cleaner
- Regenerate Thumbnails
Let’s have a look at each tool.
3.1 – Media Cleaner
Media Cleaner is an excellent free plugin that helps you clean all unused thumbnails on your site. So, first, install and activate this plugin.

Then, you will see the settings in the admin section.

Media Cleaner also offers a premium version with more advanced features, priced at 39 USD. However, with the free version, you can remove thumbnails from your WordPress site.
To begin the image scan, navigate to the Media Cleaner Dashboard.

Once there, press the Start Scan button.

After that, the plugin will scan every media on your site and show you its issues.

Media Cleaner lists all media that are not in use on your site. Those are images that you haven’t used in your blog posts, content, or widget areas.
These images are taking up precious space on your server, so it’s better to delete them. To do that, select the files you want to remove and click Delete.

This will move the selected images to the trash.
On the other hand, if you are planning to use some of those images in the future, you can simply ignore those files.

Keep in mind that if you do that, the plugin will never catch that image again.
3.2 – Regenerate Thumbnails
Another excellent tool to delete thumbnails in WordPress is Regenerate Thumbnails.

Regenerate Thumbnails is a highly popular plugin with over 1 million active installations. Let’s see how you can use this plugin on your site.
The first step is to install and activate Regenerate Thumbnails.

Under the WordPress Tools section, you will see the plugin settings.

As its name suggests, this plugin’s primary focus is to regenerate thumbnails. For example, if you have disabled the option to create thumbnails for all images on your site, WordPress won’t create any thumbnails when you update an image. However, you can tell your server to generate thumbnails manually.
With this plugin, you can create thumbnails of various sizes, which you can select from the settings.

If you have added additional image sizes or want to generate thumbnails for specific images, you can quickly create them by clicking the Regenerate Thumbnails button.

Additionally, if you have unregistered any image sizes and need to delete the thumbnails from your site, you can enable the corresponding option and start regenerating them.

Now, the plugin will start regenerating new thumbnails and deleting the old ones from your WordPress website.

How to Delete Unused Thumbnails From Your Server?
Now, let’s see how you can delete the unused thumbnails from your server and save valuable resources. For this task, you can either:
- Use an FTP client
- Use plugins
The FTP method is very time-consuming because you have to locate every image manually. Additionally, there’s a free plugin that will take care of it in no time. Let’s see how to remove all the old and unused thumbnails with it.
For this task, we will use a tool called Force Regenerate Thumbnails. This tool hasn’t been updated in a while, but it still functions quite well.
First, install and activate the plugin on your site.

Under the WordPress Tools section, you will see the plugin’s settings.

When you click the Regenerate All Thumbnails button, the server starts fetching all images on your site and regenerating their thumbnails according to the image sizes you set.
And if you have old image sizes that don’t adjust to those parameters, those unused images will be deleted from the server! This is a bulk process, making it an easy way to remove all unused images from your server.
This will help you save server resources and potentially improve your site’s performance.
Pro-Tip
If you plan to use custom-sized images on your site, we recommend specifying the size in the media settings. This way, WordPress will generate thumbnails only in those sizes.
For example, if you are going to use the 1024*1024 size, you can set that and disable the other two options as follows:

This will help you optimize the images you upload and save space on your server.
Bonus: How to View the Thumbnails Generated by Your WordPress site?
If, after reading this post on how to delete thumbnails in WordPress, you’re still wondering if this is happening to you, there’s a quick way to check.
To view all the media files you have uploaded to your site, go to your WordPress admin > Media > Library. However, you won’t find the thumbnails there. There are two main options to check the number of images you have on your site:
- Some hosts allow you to view the directory of all the files using the File Count in the File Manager.
- Another option is to use an FTP client to count the files in the Uploads folder. If you have images stored in different months or years, you will need to add the number of files to get the total. The number of thumbnails you have will be the difference between the total number of images and the number of files in the Media Library.
Another way to identify the thumbnails is by examining the file names. In most cases, thumbnails are named after the parent image, followed by the dimensions. For example, if you have an image called “test-image.jpg”, the thumbnail, which is 150×150 pixels, will be called “test-image-150×150.jpg”.
In any case, if you can’t figure out how many images you have on your site, you can contact your hosting company and ask them for help.
Common Mistakes When Removing Thumbnails in WordPress
Avoid these frequent errors to prevent layout issues or broken images on your site.
- Deleting thumbnail files directly from the server instead of using proper cleanup tools
- Removing image sizes without checking theme or page builder dependencies
- Forgetting to regenerate thumbnails after updating size settings
- Disabling image sizes required by WooCommerce or other plugins
- Assuming all custom sizes are unnecessary without auditing the site
- Using multiple media plugins that conflict with each other’s image settings
- Not testing changes on a staging site before applying them to production
Frequently Asked Questions
Now, let’s take a look at some of the frequently asked questions regarding this topic.
WordPress generates multiple thumbnail sizes so themes, page builders, and plugins can load images optimized for different layouts. This improves performance by serving appropriately sized photos instead of large originals.
Yes, it is generally safe, as long as you keep the sizes required by your theme and plugins. Deleting unused thumbnails frees storage, but always back up before removing them to avoid accidental loss of needed files.
If a required size is missing, WordPress may stretch, blur, or crop the available image incorrectly. Some layouts may also break or display an uneven grid, depending on how your theme handles missing sizes.
You can check your theme documentation or inspect your theme’s functions.php file for add_image_size entries. Some themes also list image sizes in the Customizer or theme settings panel.
It may reduce server load and decrease backup size, but it doesn’t directly affect front-end loading unless the removed sizes were unused. The most significant performance improvement comes from serving correctly sized images, not the number of images stored.
Yes, WooCommerce relies on specific image sizes for product catalogs, single product pages, and thumbnail grids. Removing required sizes can distort product images or break layout consistency.
Yes. Regenerating thumbnails updates all existing images to match your new size settings. It removes outdated sizes and ensures your site displays consistent, properly cropped images everywhere.
Conclusion
All in all, every time you upload an image, WordPress generates several thumbnails. If you don’t manage this correctly, you’ll end up with numerous unused images that consume valuable server resources.
This can slow down your site and, since most hosting companies have a limit on the number of files, also incur additional costs for server upgrades.
To resolve this issue, delete any old or unused thumbnails from your WordPress site. Here, we’ve shown you three different methods to do it:
- Manually
- From the WP-Admin
- With plugins
All of them have pros and cons, but we recommend using plugins. You can use Media Cleaner to find the unused images and delete them.
Additionally, Force Regenerate Thumbnails can help you quickly generate new thumbnails and remove the old ones. Both plugins are free and extremely easy to use, so that’s our best-recommended method from the list.
On the other hand, if you don’t want to use plugins, you can remove old thumbnails from the WP-Admin. It’s very easy and effective.
Finally, if you plan to use custom-sized images on your site, specifying the size from the WordPress dashboard is a great choice. And when you change your theme or delete image sizes, regenerating thumbnails with the Force Regenerate Thumbnails plugin will save you a lot of time.
Here’s how you can remove thumbnails in WordPress. If you found this guide helpful, please consider sharing it on social media. For more WordPress-related tutorials, you can always check out our blog section.
Which method to delete thumbnails did you use?
Do you know any other methods?
Leave a comment below and let us know!

10 comments
Balazs
Hi,
I would like to use this force regenerate thumbnails plugin, but first of all I have to know that if I use it the regenerated pictures URL will change?
I uploaded them in folders like …./uploads/2021/01/….. So this will stay like it was or the new pictures gonna get the new folder in the URL like this: ….uploads/2022/03/…..
Could you help me with this question?
Trisha
this worked great! I got rid of so much junk. My file sizes are much more lightweight than the ones that WordPress generated as thumbnails, so my page loads faster.
I have one problem though. I trashed one of the sizes that WordPress is still trying to show. So about half of my posts’ images are broken. I see where to fix it but I don’t know how to do it programmatically.
Do you know of a way to bulk fix something like this
change this code:
<img src="https://my.site/wp-content/uploads/image-922×1024.png" (broken link)
to this code:
<img src="https://my.site/wp-content/uploads/image.png"
Fabrice
Media Cleaner est trés utile pour faire le ménage merci MEOW
Jérôme
Merci pour ces informations j’utilise media Cleaner depuis un moment mais le tuto va un peu plus loin parfait
Le Huu Vinh
Good job. Thanks.
german
You’re welcome
Dorota
Will removing the thumbnails from the WP-Admin Panel work also for thumbnails of already uploaded files? Or does it work just from now on?
Jane
It will help you with future thumbnails, Dorota
Naim
After reading your post I was able to perfectly delete the WordPress Thomsonail.
german
Great!