How to compress an image to a target size in KB
If an upload form rejects a large file, use its size limit as a target. The tool tries several JPEG or WebP quality levels and reports the size it can achieve.
Guests can process one file up to 5 MB. Sign in to use a larger file.
Input
Output
Your result will appear here.
Your input is processed locally in this browser and is not uploaded by this tool. Tool activity
Steps
- Select the original PNG, JPEG, or WebP file and check its size.
- Choose JPEG if the form requires JPG. Enter a target such as 200 KB and compress.
- Check the size and inspect fine detail, then download the result if it meets the requirement.
Worked example
For a 900 KB photo with a 200 KB upload limit, set a target of 190 KB. Choose JPEG if required. Allow resizing only if the recipient accepts it.
Why use this tool?
- Start with the upload form’s KB limit instead of re-exporting at random quality settings.
- Keep the pixel dimensions while finding the best available quality for the chosen size.
What to do when the result is above the limit
The lowest quality at the original dimensions may still produce a file above the limit. Enable Allow resizing and compress again if the recipient accepts smaller pixel dimensions.
Keep the original. For strict upload limits, set a target slightly below the stated maximum.
Frequently asked question
Can I keep PNG as the output?
Automatic keeps a PNG that already meets the limit. For compression, choose WebP or JPEG. JPEG fills transparent areas with white.