Skip to content
//Image Resizer & Converter example\\

Thumbnails in the original format

Base64 images and links (animated GIF, HEIC, PNG) padded to 300x300 squares, each kept in its own format.

Updated November 12, 2026

What this example returns

The dataset’s “Files” view shows 14 columns: Preview, File, Format, Width, Height, Bytes, Saved %, Size, Source, Source format, Source width, Source height, Source bytes, and Error. See every output field.

What each setting does

The input this example runs Image Resizer & Converter with. “Try this input” opens it in the console, where you can run it as-is or change any field first.

Image URLs imageUrls

https://upload.wikimedia.org/wikipedia/commons/2/2c/Rotating_earth_%28large%29.gif, https://raw.githubusercontent.com/bigcat88/pillow_heif/v1.8.1/tests/images/heif/RGB_8__128x128.heif, https://upload.wikimedia.org/wikipedia/commons/4/47/PNG_transparency_demonstration_1.png

Direct links to the images, one per line: JPEG, PNG, WebP, GIF (animated too), AVIF, HEIC/HEIF, TIFF, BMP or ICO, up to 100 MB each. Google Drive, Dropbox and GitHub share links are turned into download links automatically. Each image gives one file per output size. You can also (or instead) take images from a…

Width (px) width

300

Target width in pixels. Leave empty to set only the height, or leave both empty to keep the size and only convert or compress. With only one side set, the other follows the image's proportions.

Height (px) height

300

Target height in pixels. With both width and height set, 'Fit' decides how the image fills that box.

Fit fit

Contain (fit and pad)

How the image fits a box when both width and height are set. Inside: keep proportions, fit within the box (no cropping). Cover: fill the box exactly and crop what sticks out. Contain: fit within the box and pad the rest with the background colour. Fill: stretch to the exact size.

Default: Inside (keep proportions, no crop) → this example uses Contain (fit and pad)

Output format format

Same as source

File format of the results. WebP and AVIF give the smallest files, JPEG opens everywhere, PNG is lossless with transparency. 'Same as source' keeps each image's own format (HEIC becomes JPEG).

Default: WebP → this example uses Same as source

Background colour background

transparent

Colour for the padding of 'Contain' and for transparent areas in formats without transparency (JPEG, BMP): a hex code such as #ffffff, a colour name, or 'transparent' (padding stays transparent in WebP, PNG, AVIF, GIF and TIFF).

Default: #ffffff → this example uses transparent

Base64 images base64Images

{"name":"badge.png","base64":"iVBORw0KGgoAAAANSUhEUgAAAEAAAAAoCAYAAABOzvzpAAAAyElEQVR42u2ZwRGDMAwErSskrxSZElIkrzSSVADYRsS+893foN3RwMgqxXGclRP/etHjtX1bz3zez6AU0AM7SkrMDny3kGAFzxIR7OBXRYQKeK8IKMK31AtF+Ja6oQpfWz+U4Ws4oA5/xoMV4I+4UBaPBazS/nt87gALsAALSL1gYJsS3QEWcOEygb39DztATcIeD3oOqcBXfQPYJZzVj4yHsMI3/…

Images sent as text, for API calls and small tests: a list of {"name": "photo.jpg", "base64": "..."} objects, base64 strings or data:image/... URLs.

.json
{
  "imageUrls": [
    "https://upload.wikimedia.org/wikipedia/commons/2/2c/Rotating_earth_%28large%29.gif",
    "https://raw.githubusercontent.com/bigcat88/pillow_heif/v1.8.1/tests/images/heif/RGB_8__128x128.heif",
    "https://upload.wikimedia.org/wikipedia/commons/4/47/PNG_transparency_demonstration_1.png"
  ],
  "base64Images": [
    {
      "name": "badge.png",
      "base64": "iVBORw0KGgoAAAANSUhEUgAAAEAAAAAoCAYAAABOzvzpAAAAyElEQVR42u2ZwRGDMAwErSskrxSZElIkrzSSVADYRsS+893foN3RwMgqxXGclRP/etHjtX1bz3zez6AU0AM7SkrMDny3kGAFzxIR7OBXRYQKeK8IKMK31AtF+Ja6oQpfWz+U4Ws4oA5/xoMV4I+4UBaPBazS/nt87gALsAALSL1gYJsS3QEWcOEygb39DztATcIeD3oOqcBXfQPYJZzVj4yHsMI3/QXYJNTW671A5mjJBJ4iYAYRQ3eDI4RMuR2+S4r6YOY4E+QHNaJkOBNFR1UAAAAASUVORK5CYII="
    },
    "data:image/gif;base64,R0lGODlhKAAYAIEAAP8AAAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQAHgAAACwAAAAAKAAYAAAINAABCBxIsKDBgwgTKlzIsKHDhxAjSpxIsaLFixgzatzIsaPHjyBDihxJsqTJkyhTqlzpMCAAIfkEAR4AAQAsAAAAACgAGACBAKAAAAAAAAAAAAAACDQAAQgcSLCgwYMIEypcyLChw4cQI0qcSLGixYsYM2rcyLGjx48gQ4ocSbKkyZMoU6pc6TAgACH5BAEeAAEALAAAAAAoABgAgQAA/wAAAAAAAAAAAAg0AAEIHEiwoMGDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXOkwIAA7"
  ],
  "width": 300,
  "height": 300,
  "fit": "contain",
  "background": "transparent",
  "format": "original"
}

What it costs

You pay for the events the actor reports, such as each result or page it produces. Platform usage is included in the event prices: compute, proxies, browser and storage cost nothing extra.

  • Image up to 500 KB$0.0017One resized or converted file made from a source image of up to 500 KB.
  • Image 10 to 25 MB$0.0102One resized or converted file made from a source image of 10 to 25 MB.
  • Image 2 to 10 MB$0.00425One resized or converted file made from a source image of 2 to 10 MB.
  • Image 500 KB to 2 MB$0.00255One resized or converted file made from a source image of 500 KB to 2 MB.
  • Image 25 to 50 MB$0.02125One resized or converted file made from a source image of 25 to 50 MB.
  • Image 50 to 100 MB$0.051One resized or converted file made from a source image of 50 to 100 MB.

Full pricing

When to use this example

From the Image Resizer & Converter readme:

Why is a file bigger than the original?

Converting an already small, compressed image (for example a JPEG to PNG, or lossless WebP) can make it larger. savedPercent is then negative. Use WebP or AVIF with a quality around 80, or set a maximum file size.

What happens with HEIC, animated GIFs and transparency?

HEIC/HEIF is read like any other image. Animated GIF and WebP stay animated when the output is WebP, GIF or PNG. Transparency is kept in WebP, PNG, AVIF, GIF, TIFF and ICO; JPEG and BMP get the background colour instead.

Other ways to run Image Resizer & Converter

All examples of Image Resizer & Converter

About Image Resizer & Converter

Resize, crop, convert and compress images in bulk from links, datasets or uploaded files: WebP, AVIF, JPEG, PNG, GIF, TIFF, BMP and ICO, HEIC input, several sizes per image, target file size, EXIF removal and animated GIF/WebP. One row per file with a download link, plus a ZIP of all files.

Price:
$1.70 / 1,000 results
Developer:
Echofield

Image Resizer & Converter pageOutput fieldsPricing

Related actors

//From the blog\\

Latest articles

All articles

The internet is full of data.
Start owning yours.

Scrape.ly gives you the infrastructure, the tooling, and the team to extract, process, and operationalize web data at any scale. Setup takes minutes.

No credit card. No setup calls.