Resize image
resize_imageResize images by width, height, or percent while preserving aspect ratio. Optionally enlarge, set output format, and adjust quality locally without uploading.
Instructions
Resize by width, height or percent. Keeps the aspect ratio (fit=inside) and never enlarges unless enlarge=true. Lanczos3 resampling.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fit | No | ||
| input | Yes | ||
| width | No | ||
| format | No | ||
| height | No | ||
| output | No | Output file path. Default: next to the input, with a suffix and the right extension. | |
| enlarge | No | ||
| percent | No | ||
| preview | No | Attach a small JPEG preview to the result (default true). | |
| quality | No | Lossy quality 1-100 (default 80). Ignored for png. | |
| background | No | CSS color used to flatten transparency when the output is jpeg (default #ffffff). |