WP is creating multiple files for every image uploaded - more than 4


First, I did check out the 'Community" and documentation (CODEX) for a solution to this, but couldn't find it. And, did the google search as recommended in "The Good Support Ticket" tutorial. No help.

When we upload an image (picture) into a Wiki (we have a CMS), WP doesn't just create the 4 sizes (thumbnail, sml, med, large). If we have to change the size of the image, especially when grabbing a corner, side, top or bottom of it once it is uploaded, every time we change the picture size WP creates a new file. I checked out this plugin which was recommended in a post about almost the same issue, "Additional image sizes", but it doesn't deal with the issue of 10s of thousands of unwanted and unused image files saved in my DB. I did a cursory review in the 'uploads' folder and found some pictures with over 20 files saved, all different sizes. See attached screenshot.

This issue is no doubt making our database significantly larger than it needs to be. Our response time is sooooooo slow, and I believed it was largely due to the amount of content we have - over 1400 Wikis and growing. But now I'm thinking the number of image files has a lot to do with it. BTW, I have 'smushed' the image files and that only helped a little.

Can you suggest a plugin, or method of globally removing all unused image files other than going into the uploads folders (14 months of uploads) and deleting them individually? There has got to be some plugin or code that can see when a file was last accessed, and deleting all those files that have never been accessed.

Support access has already been granted.

Thank you very much in advance for your assistance.

Mary Todd

  • Adam Czajczyk

    Hello Mary,

    I hope you're well today and thank you for your question!

    I think those additional images must come from one of your other plugins as WordPress itself and Wiki Pro shouldn't work like this. I'd suspect either Next Gen gallery or a a Page Builder though I admit I've never came across that issue.

    However, I agree that the most important step here (otherwise we wouldn't even be able to identify the main culprit) would be to clean up images. Partially, it could be done manually:

    - go to your Media Library
    - from the drop-down box that by default says "All media items" select "Unattached" and click on "Filter" button
    - this should present you with a list of images that aren't attached to any post/page

    Assuming that those images aren't used in any other way (e.g. by content generated directly by other plugins) you could then bulk-delete them.

    Another way would be to give this plugin a try:

    Please take a look at its FAQ page first here:

    Make also sure that you made a full backup of the site prior to any of operations proposed above. I realize this may be a time consuming task but in case anything went wrong or didn't work as expected it will save you from catastrophe.

    I hope that helps!
    Best regards,

  • Mary

    Hi Adam,

    Nice to hear from you.

    First, oddly, all those 10's of thousands of unused image files do not show up when I go to Media and click "unattached". See the attached screen shot. There are only 26 unattached files, a tiny number compared with the many thousands of unused image files in my DB. Also, I don't use any gallery plugins, though I've downloaded one or two, I never activated them. (I should delete them). Lastly, have you read the comments users made about the dnui-delete-not-used-image-wordpress/ plugin? It's name should possibly be Do Not Use In perpetuum, instead of Delete Not Used Image. (trying to be funny). There are more negative remarks about it (17) than positive (15). And it hasn't been updated in 5 years. Sorry, Adam, but I don't need more time-consuming problems, but nice idea if it was any good. (you really shouldn't recommend using software that hasn't been updated in years, and has such bad feedback). :o)

    As far as Page-Builder, I have used Page-Builder on 'maybe' 2 or 3 Wikis to try it out. Then I read about all kinds of problems related to using it, so I stopped. I do not believe it went into over a year of installed images, in over a dozen unique folders, and duplicated them. I can test this, but if it was generating so many possible sizes of images that are not in the same wikis, why do some images have 9 sizes, and others have over 20? If a given plugin was creating many different sizes of pics, it would seem logical that it would create the same sizes for every picture, much like WP documentation says it is creating 4 standard sizes for every imported picture (sml, med, lrg, and thumbnail).

    So I just tested my theory about Wiki Pro creating this problem. Sorry, but it appears I'm correct. We made one Wiki titled Test For Image Duplication. Inserted some text and one picture. Did not touch, move, do anything to the picture. Saved it. Checked Cpanel, and in wp-content/uploads/2016/02 there were 9 copies of the picture in various sizes (WP documentation says it makes 5). Then made another new wiki, Test for Image Duplication 2. This time, that single picture was 'grabbed' by each corner and moved. WP Wiki Pro created 18, yes EIGHTEEN files. There is always 1 of the original picture, and the other 17 are copies in various sizes. Please see screenshots attached. We tested various actions and then deactivated every plugin except Wiki. By the time we got to Test 7, which was with every plugin turned off except WIKI (see attachment) WP was consistently making 18 files for every 1 (one) picture. So obviously a plugin I had installed was actually only "allowing" WP WIKI to make 9 instead of 18 IF we didn't move or resize it. Don't know which one it was, and it doesn't matter at this point because Wiki is making 18 files for every 1 picture I upload with every plugin turned off.

    OK, so now I have figured it out. And I must mention, again, that turning off every plugin did nothing except cause me more time and work (I have to get that comment in - because I understand that some plugins DO cause problems like the one you mentioned for me to use). But I really DO read documentation, and user comments, and web comments, etc. . . before I install anything to my site.

    So I have the problem of possibly 10s of thousands of picture files created by the WP Wiki software. They can't be removed by using WP software using the Media Library unattached files function. They can only be seen in the files on my host's server, as indicated and shown in screenshots.

    So, I need the following:
    1. Get the Wiki plugin to stop making multiple copies of every picture. Even 5 wasn't acceptable (and I have no clue why someone thought it was necessary), but it IS making 18 for every 1 picture (1 + 17).
    2. I need a piece of software/code that will remove all extraneous files from my uploads folders on the server. This was caused by the wiki software. I have no 'tools' to find out which one is in use. And when I 'smushed' all the pics on the 9th of Feb, almost every picture now says it's latest modification date is 9 Feb, so mod date in Cpanel doesn't help. I have over 1400 Wikis. Most have many more than 1 or 2 pictures. Some wikis have dozens. Multiply that by 18 . . .

    Please advise.

    Mary :o(

    Info: I am using Windows 7. Windows 7 is up to date. Google Chrome Version 48.0.2564.109 m. Google Chrome is up to date. My WP is version

  • Mary

    Additional info: We create Wikis on both my Win 7 op system laptop, and a Win 10 laptop. Both have the latest versions and all the patches for their operating systems. Google Chrome is up to date on both. I am not using any other browser when I create Wikis. I am advising you of this because I can recall a Support Ticket I made a while back when my browser and operating system were brought into the discussion on why something was occurring. Most of our test wikis created to determine the cause of this problem were on the Win 10 laptop. But some were on the Win 7. Multiple image files were created by Wiki Pro regardless of the operating system.

    Can you, Adam, or someone else PLEASE at least reply.

    Thank you.


  • Michael Bissett

    Hey @savemarytoddsleg,

    1. Get the Wiki plugin to stop making multiple copies of every picture. Even 5 wasn't acceptable (and I have no clue why someone thought it was necessary), but it IS making 18 for every 1 picture (1 + 17).

    Right now, when I try editing an image once inside of a fresh WordPress site (no other plugins, not even Wiki Pro, have been installed yet), I do see that an additional 3 images are created in my uploads folder, and when I make another edit, then 3 more images come up:


    The same sort of behavior takes place on my site with Wiki Pro enabled, when I try performing the same steps. Right now, this tells me that we're encountering behavior belonging to WordPress itself (rather than Wiki Pro), and it seems like you're running into this too (though I notice a difference in filenames). I need to confirm that I'm following in your steps exactly here, to know for certain.

    If you can record video of you doing this, with a tool like this:


    And post that here, that'd be immensely helpful. :slight_smile:

    2. I need a piece of software/code that will remove all extraneous files from my uploads folders on the server.

    In trying to research this, folks look to be liking this plugin over here, it's definitely a newer plugin than what's available elsewhere in the WordPress universe:


    Kind Regards,

  • Mary

    <!-- copy and paste. Modify height and width if desired. -->
    <object id="scPlayer" width="1366" height="661" type="application/x-shockwave-flash" data="http://content.screencast.com/users/NSMmt01/folders/Jing/media/71189a93-7506-473f-8a3c-92cf316caab3/jingswfplayer.swf" >
    <param name="movie" value="http://content.screencast.com/users/NSMmt01/folders/Jing/media/71189a93-7506-473f-8a3c-92cf316caab3/jingswfplayer.swf" />
    <param name="quality" value="high" />
    <param name="bgcolor" value="#FFFFFF" />
    <param name="flashVars" value="thumb=http://content.screencast.com/users/NSMmt01/folders/Jing/media/71189a93-7506-473f-8a3c-92cf316caab3/FirstFrame.jpg&containerwidth=1366&containerheight=661&content=http://content.screencast.com/users/NSMmt01/folders/Jing/media/71189a93-7506-473f-8a3c-92cf316caab3/Image%20Duplication%20problem%20video%202016-02-15_1532.swf&blurover=false" />
    <param name="allowFullScreen" value="true" />
    <param name="scale" value="showall" />
    <param name="allowScriptAccess" value="always" />
    <param name="base" value="http://content.screencast.com/users/NSMmt01/folders/Jing/media/71189a93-7506-473f-8a3c-92cf316caab3/" />
    Unable to display content. Adobe Flash is required.

  • Michael Bissett

    Hey @savemarytoddsleg,

    First off, thanks for the screencast! :slight_smile:

    Second... still not able to reproduce this over on my end, with both of these scenarios:
    - Wiki Pro's disabled, and I run through your steps with a normal post
    - Wiki Pro is enabled, and I run through your steps in creating a wiki

    I'm not running into a case of what could be called "thumbnail multiplication", this definitely calls for some spelunking over on your site. Could you please send in the following via our secure contact form:

    - Mark to my attention, the subject line should contain only: ATTN: Michael Bissett
    - Do not include anything else in the subject line, doing so may delay our response due to how email filtering works.
    - Link back to this thread
    - Include FTP log-in details (hostname, username & password)
    - Include any relevant URLs for your site

    IMPORTANT: Please make sure you select "I have a different question" for your topic, so it doesn't go back to the forums - this and the subject line ensure that it gets assigned to me.


    Kind Regards,

  • Predrag Dubajic

    Hi Mary,

    Thanks for sending in those details.

    Let me explain a bit first how WP works, after you have upload an image it will add that original image to your uploads folder and create thumbnails that are defined by theme/plugin you are using, only main image will show in media gallery and thumbnails will be called where theme/plugin defines it.

    I've downloaded your active theme and run a search for add_image_size which is a function to create specific thumbnail on image upload.
    And I got 40 results, as you can see on screenshot attached below.

    So the issue here is your theme which creates large number of thumbnails and it's best to contact your theme developer to see which ones could be removed in your setup.

    Hope this makes sense and clears things up :slight_smile:

    Best regards,

  • Mary

    Wow, Though I have Minimaze Pro, I am using the 'free' version of Minimaze. However, I have no reason to believe it's not Minimaze that is doing this.

    THANK YOU so VERY much for finding this. I am in the process of using one of the new WPMU Dev themes, cause I have had so many problems with non-WPMU Dev themes and plugins. I applaud you ALL for the TOP SHELF products and support you have. Your annual fee was in our 2016 budget, cause I would have so much difficulty without ALL of you.

    THANK YOU, again!!

    Mary Todd
    a project of Collections and Curation

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.