How to reduce image sizes to upload to forum attachment

Anything not related to Diablo (Off-topic).
Post Reply
Site Admin
Posts: 288
Joined: Sun Dec 19, 2021 11:23 am

How to reduce image sizes to upload to forum attachment

Post by fearedbliss »

Hey all,

As you all know, the forum currently has a 2 MB limit on each attachment posted. This is primarily to keep the server storage requirements down since most of the images people will be uploading on the forums will be in-game screenshots which take around 300-500 KB. Although sometimes we want to upload other types of images, or desktop screenshots, etc, which could go up to even 5-6 MB+. For these situations, I recommend using something like GIMP, ImageMagick, or another utility to reduce the file size to 75% or lower, and/or strip out any additional image metadata that isn't needed for these purposes.

On Linux you could install the "imagemagick" package which will allow you to easily reduce the image sizes down. Due note that the following command will do an in-place overwrite of the image, so make sure to back up the image first before doing the compression so that if you need to re-run the command with a different quality value, you could re-run the command on the original image.

Code: Select all

mogrify -quality 65 <image file name>
- fearedbliss
Post Reply