Crop images
Crop one JPG, PNG or WebP using a preview selection or pixel coordinates.
- 1Add input
- 2Adjust settings
- 3Get your result
Tool input and files are processed in this browser without being uploaded.
Before you start
Choose the part of one static JPG, PNG or WebP to keep. Select “Read local preview” to drag a rectangle, or enter its left, top, width and height as whole pixel values. Coordinates refer to the image as decoded for display. The output uses the selected pixel dimensions; this tool does not resize the crop.
How to use this tool
- Choose one saved JPEG, PNG or WebP image. The original stays on your device.
- Enter whole pixel values for left and top. Leave width or height blank to crop to the right or bottom edge. To use a selection, choose “Read local preview”, then drag a rectangle and choose Free, 1:1 or 16:9 if needed. Check the final width and height after choosing a ratio.
- Select “Crop image”, inspect the cropped image and its pixel dimensions, then use “Download” to save it. “Copy result” copies the complete JSON details, not the image. Keep the original and compare detail, colors and transparency before replacing it.
Supported inputs and limits
One static JPG, PNG or WebP, up to 20 MiB and 16 million pixels in the source image. The browser must be able to decode it. Animated images and SVG are not supported.
Left and top must be zero or positive whole pixels inside the image. Width and height must be positive whole pixels and fit the remaining area. Dragged selections and fixed aspect ratios are rounded to whole pixels and kept within the image.
File names, including the extension, can contain at most 512 UTF-16 units; some emoji count as two. Shorten an overlong name before selecting it. The output extension follows the detected image format: .jpg, .png or .webp. The download can have the same name as the source, so keep the original.
Worked example
Example input
pixels.png
Example options
{
"x": 0,
"y": 0,
"width": 100,
"height": 100
}Example output
{
"items": [
{
"inputBytes": 804,
"outputBytes": 592,
"width": 100,
"height": 100,
"inputMetadata": [],
"outputMetadata": []
}
]
}When something does not work
For invalid coordinates, use whole pixel values with left and top inside the image and width and height within the remaining area. Read the preview and select Free to edit both dimensions independently. If the source is too large, reduce its file size or pixel dimensions in another image app first; selecting a small crop does not bypass the source limit. Shorten an overlong file name. For an unreadable or animated image, export a complete static JPG, PNG or WebP and select it again. If image decoding or encoding is unavailable, reload this page or try a browser with the required image support. A failed or cancelled crop provides no new image. If an older result remains after a preview error or cancellation, it belongs to the previous run. After correcting the input, select “Crop image” again and check the new download.
Frequently asked questions
Are my files uploaded?
No. Your image is processed in this browser. The tab can keep inputs and results temporarily, within time and memory limits. Older workspaces may be cleared, and large results may need to be generated again. Refreshing or closing the tab clears this work. Keep the original and download the crop you need.
Will the crop keep its format, detail and transparency?
The cropped image is re-encoded in the format detected from the file contents, with no separate format or quality setting. JPG and WebP crops use lossy encoding, even if the source WebP was lossless. PNG and WebP can carry transparency; JPG stays opaque. Re-encoding does not guarantee identical color or alpha values, or that EXIF, XMP and ICC data are retained or removed. Check the saved image in the app where you will use it. File size may grow, and the result has no guaranteed print size or color profile. The example JSON is a sample, not a promised output size.
How do coordinates and aspect ratios work?
Left and top start at 0,0 in the image decoded by the browser for display, rather than the file's unrotated pixel grid. With both at zero and width and height blank, the whole image is selected. A blank width extends to the right edge; a blank height extends to the bottom edge. After reading the preview, Free lets you enter width and height independently. The 1:1 and 16:9 choices calculate whole-pixel dimensions and constrain them to the image, so a very small 16:9 selection may differ from that ratio. Selecting a different file resets the rectangle and preview. Check the preview's orientation and final dimensions before cropping.
Documentation & further reading
Related tools
WebP to JPG
Convert static WebP to JPG with a background color for transparent areas, then download.
PNG to JPG
Choose a background for transparent areas and save as JPG.
Batch JPG to PNG
Convert one or more JPG images to PNG files.
Image to WebP
Convert one or more JPG or PNG images to WebP with adjustable quality.