Updated on Aug 16, 2019
By default, all images uploaded into the WordPress content folder have a specific number of duplicates (different sizes). Additionally, some templates and plugins also could generate previews of the same images, some needed, and others made just in case. As a result, the number of duplicates may exceed ten images.
In case your WordPress site has a large number of photos or images, there could be some problems with the lack of disk space on the host after a while (if it’s not unlimited, of course). This post is to show you how to prevent unwanted image duplication.
We are going to cover:
Unlike page duplicates, image copies would not cause any harm to your WordPress site. What they do is to take up more space on your hosting account. Luckily, most web hosting providers provide considerable storage. However, sometimes, the storage might not be enough.
Extra duplicates of images are generated after all image uploads. After being uploaded, the image is duplicated in different sizes. Thus, in any blog post, we are loading up to 20 images. If you are not using optimized photos and images, sooner or later the disk space that your hosting provider gives you could evaporate in the blink of an eye.
Duplicate images affect the size of a backup copy of your WordPress website. In case you create the backup copy of your site in the cloud storage, or if you use some plugins, they should work with a large volume of information, which is why errors may occur.
If you find out that some image sizes are not used on your WordPress site, we advise to switch off duplication of images of this specific size. This way, you will potentially save some disk space.
Before you begin fighting duplicate images, you should know how many copies are generated from one uploaded image. By default, WordPress generates three images of different size (thumbnail size, medium size, and large size). Some templates could generate extra dimensions to create their thumbnails for sliders, or other functions.
To find out the number of additional copies that are generated, log into your FTP client, and open the directory /wp-content/uploads/
.
Removing all duplicates is not always a good idea. Even if you decide on removing the unwanted images, it would not be guaranteed that they will not appear again. When talking about the WordPress engine, there are specific settings that can actually prevent the generation of any unnecessary image sizes. If you want to do this, go to Settings → Media. After you go there, you need to reset all sizes.
Once you reset these figures, you will be able to insert into images of the highest size into the post. Later, you can adjust the size by changing the width value in the editor. You may have other sizes by default. Therefore, when an image is loaded, WordPress would automatically generate it in different sizes. The larger the size of the download, the more duplicates will exist. So, if you upload an image of 600 by 600px, larger-sized duplicates would not be generated. Consequently, the smaller the size of an uploaded image, the smaller the number of doubles created.
By now you have probably visited your content folder and counted the number of duplicates. In case you want to get rid of them, you have two options. Either do it via the File Manager in cPanel or use a plugin. We advise that you go with the first option since it will not require any installs. However, If you choose the second option, we recommend using a powerful WordPress plugin called Image Cleanup WordPress plugin.
This plugin does some great work for your images, like:
In case you are not using additional thumbnails, you can disable this functionality in the template itself. You will get rid of a large number of duplicates.
Do not forget to upload images which are optimized for the web. Try not to use the built-in WordPress function for photo editing, since it also makes duplicates and can eventually cram up your disc space.
In case this post didn’t help you solve the issue on your own, feel free to submit a support ticket. Our team of technical support experts works 24/7. You can be sure that they will assist you with everything hosting related.
We hope you find this article useful. Discover more about FastCloud - the top-rated Hosting Solutions for personal and small business websites in four consecutive years by the HostAdvice Community!