Image shrink before upload
Automatically resize images before upload
File Uploader lets you setup behavior that will shrink hi-res images before uploading.
Benefits of automatic image resize on upload:
- Users don’t need to downscale images on their devices to meet the uploading requirements.
- Optimized storage.
- Faster uploading.
Use the image-shrink
option to apply
client-side image resize with values like:
800x600
, shrinks images to 0.48 megapixels with the default JPEG quality of 80% (default, when not set).1600x1600 95%
, shrinks images to 2.5 megapixels with the JPEG quality set to 95%.
Specs and limits
The output resolution limit for image-shrink
is 268 MP (e.g., 16384x16384
).
It conforms to the maximum resolution that WebKit desktop browsers support.
We recommend not to use values greater than 16.7 MP (4096x4096
), because it’s a current limit for iOS devices.
Note: Image shrink is built on top of HTML canvas, so it can only handle formats that the browser natively supports. We recommend using the “preview” operation on image URLs to ensure that high-resolution images are delivered at a smaller size, and that images that have been resized before uploading remain intact.
Uploaded images won’t be shrunk in the following cases:
- When a client browser doesn’t support a specified output resolution.
- For images uploaded from social media and URLs
- If the
original resolution
is less than 2x larger than thetarget resolution
. For example, it won’t shrink a 2560x1560px (4 MP) image to 1600x1600px (2.5 MP). It will work if you had a 2448x3264px (8 MP) input image. This limitation preserves an optimal image quality and file size balance. - If the image color mode is CMYK.
The output format will be JPEG by default unless your input image has an alpha channel (transparency). In this case, PNG will be used instead. Grayscale images will be converted to RGB.
EXIF and ICC profile info is copied as-is and includes an original image orientation, camera model, geolocation, and other settings of an original image.