A tool to find the biggest image based on same prefix but different suffix and keep the biggest one.

A wordpress blog or website produces the same image in 10 different resolutions. Therefore, you may have the same image with same preffix many times. I dont know any tool to quickly find the biggest image based on disk size with same prefix, and delete all the others of the same prefix but lower disk size.

I think a such tool will help many others


  • 2
    Why wouldn't you simply want the images without any ?w=300&h=400 suffixes? Presumably those would be the original images without any processing or resizing done to them and therefore would be the "best" images. From your screenshot those would also be the largest filesizes.
    – Mokubai
    Commented Oct 4, 2023 at 22:27
  • 1st prob - It is not always the case. I dont know if wordpress made the original image "im.jpg" as "im.jpg?1920", artificially. 2nd prob - We speak about many folders and subfolders with many images. 3rd prob - i had the same problem with other sites that instead of prefix they changed the suffix eg. im.jpg to im-1920.jpg or im-400.jpg. So, the tool may take into account this. Commented Oct 5, 2023 at 8:35
  • For what system?
    – Destroy666
    Commented Oct 9, 2023 at 19:44
  • for a linux system Commented Oct 10, 2023 at 7:51


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.