# Bulk Image Downloader - Save Images From URLs or Web Pages (`appdata-labs/bulk-image-downloader`) Actor

Download images from a list of image URLs, or every image a web page shows: img, srcset, picture, og:image and CSS backgrounds. Files saved with width, height, type, size and SHA-256, duplicates removed, optional ZIP. Honours robots.txt. Failed images are free.

- **URL**: https://apify.com/appdata-labs/bulk-image-downloader.md
- **Developed by:** [Kobkoon Janngam](https://apify.com/appdata-labs) (community)
- **Categories:** Agents, MCP servers, Developer tools
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $7.00 / 1,000 image downloadeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Bulk Image Downloader — save images from URLs or every image on a web page

**Download a list of image URLs, or every image the web pages you name show, into one store, with a clean row per image: type, width, height, size, SHA-256, alt text and a link to the saved file.**

Built for AI agents, data teams and marketers who need the files, not a browser extension: product photos for a catalogue, the images of a set of pages for an archive, or a dataset for a vision model.

**Quick start:** press **Start** with no configuration. It saves the images from five Wikimedia Commons pages of public-domain works (The Blue Marble, the Mona Lisa, The Starry Night, Girl with a Pearl Earring, The Scream) and one public-domain image. Then paste your own image URLs, page URLs or bare domains, up to 1,000.

> **You are responsible for having the right to download the images you point this Actor at.** Most images on the web are protected by copyright. Download only images you own, have a licence for, or that are public domain or freely licensed, and respect each site's terms.

### Sample output

A run with the default input on 8 November 2026: 101 rows (39 images saved and charged; 45 duplicates, 15 images under 100 px and 2 SVGs not charged), 14.9 seconds, largest row 1,931 bytes. Some of the saved images:

| foundIn | contentType | width × height | bytes | file | sha256 |
|---|---|---|---|---|---|
| direct | image/jpeg | 960 × 645 | 255,035 | 960px-Tsunami_by_hokusai_19th_century.jpg | f615e079c64a… |
| srcset | image/jpeg | 1280 × 1328 | 485,240 | 1280px-The_Blue_Marble.jpg | 7c54369b2cb7… |
| srcset | image/jpeg | 1920 × 1520 | 1,368,799 | 1920px-Van_Gogh\_-*Starry_Night*-\_Google_Art_Project.jpg | 5eae7173d11b… |
| og | image/jpeg | 960 × 1431 | 509,287 | 960px-Mona_Lisa,\_by_Leonardo_da_Vinci,\_from_C2RMF_retouched.jpg | a4370d759344… |
| og | image/jpeg | 1280 × 1516 | 594,446 | 1280px-1665_Girl_with_a_Pearl_Earring.jpg | fc7aa0b6dcae… |
| srcset | image/jpeg | 1280 × 1589 | 622,974 | 1280px-Edvard_Munch,\_1893,\_The_Scream,\_oil,\_tempera_and_pastel_on_cardboard,\_91_x_73_cm,\_National_Gallery_of_Norway.jpg | 2fcbcc455449… |
| srcset | image/jpeg | 500 × 333 | 64,338 | 500px-Pavillon_de_Flore,\_Louvre_Museum,\_Paris_5_November_2019.jpg | df6e698cf4fc… |

The other saved images are the related works, portraits and places those pages show, most of them 250 px previews. Raise `minWidth` to 1000 to keep only the full-size pictures.

One full row, exactly as returned (`storedUrl` is shown with the store id replaced; on Apify it is the record's link in your run's key-value store):

```json
{
  "sourcePage": null,
  "imageUrl": "https://upload.wikimedia.org/wikipedia/commons/thumb/a/a5/Tsunami_by_hokusai_19th_century.jpg/960px-Tsunami_by_hokusai_19th_century.jpg",
  "finalUrl": "https://upload.wikimedia.org/wikipedia/commons/thumb/a/a5/Tsunami_by_hokusai_19th_century.jpg/960px-Tsunami_by_hokusai_19th_century.jpg",
  "status": "downloaded",
  "httpStatus": 200,
  "contentType": "image/jpeg",
  "width": 960,
  "height": 645,
  "bytes": 255035,
  "sha256": "f615e079c64a69bcb50bd6c832c9d5d35359077c216ed90bf5806ef28df01c0c",
  "altText": null,
  "foundIn": "direct",
  "storedKey": "image-f615e079c64a69bcb50bd6c832c9d5d35359077c216ed90bf5806ef28df01c0c.jpg",
  "storedUrl": "https://api.apify.com/v2/key-value-stores/<storeId>/records/image-f615e079c64a69bcb50bd6c832c9d5d35359077c216ed90bf5806ef28df01c0c.jpg",
  "reason": null
}
```

Every row has the same 15 keys, whatever happened to the image. A value the file does not give is `null`, never a guess.

Stored files are byte-for-byte copies of the originals, so any metadata embedded in a file (such as EXIF) is kept in the file; the rows never expose it.

### What it finds on a page

Each URL is fetched once and judged by its bytes. An image is saved as it is. A web page has its images extracted, in the order a reader meets them:

- **`og`** — the page's share image (`og:image`, `twitter:image`), usually its main picture
- **`srcset`** — the largest candidate of an `<img srcset>` or a `<picture><source>`, which is the full-resolution version a phone would not load
- **`img`** — an `<img src>`, including lazy-loading `data-src`
- **`css`** — `url()` in style attributes and `<style>` blocks, when `includeCssImages` is on
- **`direct`** — the URL you gave was itself an image

Relative URLs are resolved against the page and its `<base href>`. Images added only by JavaScript are not seen, because no browser runs.

### Input

| Field | Default | What it does |
|---|---|---|
| `urls` | Two Commons pages and one image | Image URLs, page URLs or bare domains, up to 1,000 |
| `mode` | `download` | `download` saves the files; `list-only` verifies type and size without saving, for less |
| `maxImagesPerPage` | 20 | Images taken from each page, 1 to 500 |
| `minWidth` | 100 | Skip images narrower than this, measured from the file itself. 0 keeps icons and logos too |
| `allowedTypes` | jpeg, png, webp, gif, avif | Formats to keep, judged by magic bytes. svg, heic, bmp, tiff and ico can be added |
| `maxImageMB` | 10 | Larger files are stopped mid-download and not charged. Up to 25 |
| `zip` | `false` | Also store every downloaded image in one `images.zip` (up to 200 MB), linked from `SUMMARY` |
| `includeCssImages` | `false` | Also take CSS background images from the page's HTML |

An entry that is not a public web address is skipped, with its reason in `SUMMARY`, and the rest still run. The run fails only when no entry can be used.

### What each status means, and what it costs

| `status` | Meaning | Charged |
|---|---|---|
| `downloaded` | Saved to the key-value store as `image-<sha256>.<ext>` | $0.01 |
| `listed` | list-only mode: a real image, type and size read from the file, nothing saved | $0.002 |
| `duplicate` | The same URL, or the same bytes, as an image already saved in this run | No |
| `too-small` | Narrower than `minWidth` | No |
| `type-not-allowed` | A format not in `allowedTypes` | No |
| `too-large` | Over `maxImageMB`; the download was stopped there | No |
| `not-an-image` | The bytes are not an image, whatever the server's Content-Type said | No |
| `robots-disallowed` | The host's robots.txt disallows this path. It was not fetched | No |
| `robots-unavailable` | robots.txt answered with an error or refused us, so nothing was fetched | No |
| `http-error` | The server answered an error, `httpStatus` says which (403 is often hotlink protection) | No |
| `unreachable` | The host did not answer, or the address leads to a private network | No |
| `no-images` | A page with no images in its HTML | No |
| `failed` | An unexpected error on this image. The others are not affected | No |

**Pricing:** $10.00 per 1,000 images downloaded (`image-downloaded`), or $2.00 per 1,000 images listed in list-only mode (`image-listed`). The run stops before your spending limit rather than past it, and images it did not reach are not fetched or charged. The price covers the transfer and storage of each file; it is not set to undercut anyone. Very large files cost more to transfer and store, which is why each file is capped at 10 MB by default and 25 MB at most.

### What it refuses to do

- **No login, no cookies, no paywalls.** Only what opens without signing in is fetched.
- **No hotlink bypass.** No faked Referer and no retry around a 401 or 403: the status is recorded and the run moves on.
- **robots.txt is honoured** for every page, every image and every redirect hop, for the token `bulk-image-downloader`.
- **No private networks.** Every hop is checked; a link that redirects to an internal address is refused.
- **No active SVG.** SVG is off by default because an SVG file can carry script. When you add `svg` to `allowedTypes`, each SVG is stored with the content type `text/plain; charset=utf-8`, so its storage link shows the source instead of running it. The file itself is unchanged.
- **No personal metadata.** Dimensions come from the image header. EXIF is not read, so no GPS position, camera serial or owner name appears in a row. No face detection.

It is polite by construction: at most 2 requests at a time to one host and 8 overall, one truthful user agent naming this Actor, and each file streamed with a byte cap.

### FAQ

**Where are my files?** In the run's default key-value store, under `storedKey`. `storedUrl` is a direct link. The same image found twice is saved once.

**Why did an image I can see come back `http-error` 403?** The site refuses requests that do not come from its own pages. That is its decision, it is not worked around, and you are not charged.

**Can an AI agent call this?** Yes. There are no required fields, every row stays under 4 KB and the schema describes each field.

### Works well with

Same publisher, same output conventions, same honest-failure rules:

- [**commons-image-search**](https://apify.com/appdata-labs/commons-image-search) — Free-licensed images by keyword, with licence, author and attribution text.

### Disclaimer

This Actor is unofficial and not affiliated with, endorsed by or connected to Wikimedia Commons or any website whose images it reads. It fetches only the URLs you give it and the images those pages show, identifying itself honestly, honouring robots.txt and never circumventing a login, paywall or hotlink protection. You are responsible for having the right to download and use the images.

# Actor input Schema

## `urls` (type: `array`):

A mix of direct image URLs (https://example.com/photo.jpg) and web pages whose images you want. Full URLs or bare domains, up to 1000. Each is fetched once and judged by its bytes: an image is saved, a page has its images extracted. No links are followed. An entry that is not a public web address is skipped with its reason in SUMMARY, and the rest still run. You must have the right to download the images you point it at.

## `mode` (type: `string`):

"download" saves each image to the key-value store and returns its storedUrl. "list-only" verifies each image (type, width, height) without saving it, reading only its first 512 KB, and costs less.

## `maxImagesPerPage` (type: `integer`):

How many images to take from each web page, in page order with the share image (og:image) first. 1 to 500. Direct image URLs are not limited by this.

## `minWidth` (type: `integer`):

Skip images narrower than this many pixels, measured from the file itself, not the page's HTML. The default 100 leaves out icons and logos; set 0 to keep every size.

## `allowedTypes` (type: `array`):

Keep only these formats, judged by the file's magic bytes. Any of: jpeg, png, webp, gif, avif, svg, heic, bmp, tiff, ico. SVG is off by default because it can carry script; when you add it, each SVG is stored as text/plain so it never runs from its storage link, and the file itself is unchanged.

## `maxImageMB` (type: `number`):

Images larger than this are stopped mid-download and returned as too-large, not charged. Up to 25.

## `zip` (type: `boolean`):

In download mode, also store every downloaded image in one ZIP file (key images.zip, up to 200 MB). Its link is in the SUMMARY record. The ZIP is not charged.

## `includeCssImages` (type: `boolean`):

Also take images from url() in the page's style attributes and <style> blocks, such as hero backgrounds. Stylesheets in separate files are not read.

## Actor input object example

```json
{
  "urls": [
    "https://example.com/gallery/",
    "https://example.com/images/photo.jpg"
  ],
  "mode": "list-only",
  "maxImagesPerPage": 100,
  "minWidth": 400,
  "allowedTypes": [
    "jpeg",
    "png"
  ],
  "maxImageMB": 5,
  "zip": true,
  "includeCssImages": true
}
```

# Actor output Schema

## `rows` (type: `string`):

One row per image: where it was found, its metadata and the link to the saved file, or why it was not saved

## `files` (type: `string`):

The key-value store holding every downloaded image, keyed by SHA-256 and extension, and images.zip when asked for

## `summary` (type: `string`):

URLs read and skipped, images found, saved and charged, how many ended in each status, the ZIP link, and why each uncharged image was not saved.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "urls": [
        "https://commons.wikimedia.org/wiki/File:The_Blue_Marble.jpg",
        "https://commons.wikimedia.org/wiki/File:Mona_Lisa,_by_Leonardo_da_Vinci,_from_C2RMF_retouched.jpg",
        "https://commons.wikimedia.org/wiki/File:Van_Gogh_-_Starry_Night_-_Google_Art_Project.jpg",
        "https://commons.wikimedia.org/wiki/File:1665_Girl_with_a_Pearl_Earring.jpg",
        "https://commons.wikimedia.org/wiki/File:Edvard_Munch,_1893,_The_Scream,_oil,_tempera_and_pastel_on_cardboard,_91_x_73_cm,_National_Gallery_of_Norway.jpg",
        "https://upload.wikimedia.org/wikipedia/commons/thumb/a/a5/Tsunami_by_hokusai_19th_century.jpg/960px-Tsunami_by_hokusai_19th_century.jpg"
    ],
    "mode": "download",
    "maxImagesPerPage": 20,
    "minWidth": 100,
    "allowedTypes": [
        "jpeg",
        "png",
        "webp",
        "gif",
        "avif"
    ],
    "maxImageMB": 10,
    "zip": false,
    "includeCssImages": false
};

// Run the Actor and wait for it to finish
const run = await client.actor("appdata-labs/bulk-image-downloader").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "urls": [
        "https://commons.wikimedia.org/wiki/File:The_Blue_Marble.jpg",
        "https://commons.wikimedia.org/wiki/File:Mona_Lisa,_by_Leonardo_da_Vinci,_from_C2RMF_retouched.jpg",
        "https://commons.wikimedia.org/wiki/File:Van_Gogh_-_Starry_Night_-_Google_Art_Project.jpg",
        "https://commons.wikimedia.org/wiki/File:1665_Girl_with_a_Pearl_Earring.jpg",
        "https://commons.wikimedia.org/wiki/File:Edvard_Munch,_1893,_The_Scream,_oil,_tempera_and_pastel_on_cardboard,_91_x_73_cm,_National_Gallery_of_Norway.jpg",
        "https://upload.wikimedia.org/wikipedia/commons/thumb/a/a5/Tsunami_by_hokusai_19th_century.jpg/960px-Tsunami_by_hokusai_19th_century.jpg",
    ],
    "mode": "download",
    "maxImagesPerPage": 20,
    "minWidth": 100,
    "allowedTypes": [
        "jpeg",
        "png",
        "webp",
        "gif",
        "avif",
    ],
    "maxImageMB": 10,
    "zip": False,
    "includeCssImages": False,
}

# Run the Actor and wait for it to finish
run = client.actor("appdata-labs/bulk-image-downloader").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "urls": [
    "https://commons.wikimedia.org/wiki/File:The_Blue_Marble.jpg",
    "https://commons.wikimedia.org/wiki/File:Mona_Lisa,_by_Leonardo_da_Vinci,_from_C2RMF_retouched.jpg",
    "https://commons.wikimedia.org/wiki/File:Van_Gogh_-_Starry_Night_-_Google_Art_Project.jpg",
    "https://commons.wikimedia.org/wiki/File:1665_Girl_with_a_Pearl_Earring.jpg",
    "https://commons.wikimedia.org/wiki/File:Edvard_Munch,_1893,_The_Scream,_oil,_tempera_and_pastel_on_cardboard,_91_x_73_cm,_National_Gallery_of_Norway.jpg",
    "https://upload.wikimedia.org/wikipedia/commons/thumb/a/a5/Tsunami_by_hokusai_19th_century.jpg/960px-Tsunami_by_hokusai_19th_century.jpg"
  ],
  "mode": "download",
  "maxImagesPerPage": 20,
  "minWidth": 100,
  "allowedTypes": [
    "jpeg",
    "png",
    "webp",
    "gif",
    "avif"
  ],
  "maxImageMB": 10,
  "zip": false,
  "includeCssImages": false
}' |
apify call appdata-labs/bulk-image-downloader --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,appdata-labs/bulk-image-downloader"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/TjcMDV9SRhwgdHAe9/builds/FmD1NyByzZC3sHCtA/openapi.json
