# Docker Hub Images Scraper (`zerobreak/docker-hub-images-scraper`) Actor

Docker Hub Images Scraper is a Python tool designed to extract repository metadata, image tags, download counts, star ratings, and update histories from Docker Hub. It exports structured container registry datasets into clean CSV or JSON formats for infrastructure analysis.

- **URL**: https://apify.com/zerobreak/docker-hub-images-scraper.md
- **Developed by:** [ZeroBreak](https://apify.com/zerobreak) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.99 / 1,000 results

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

### Docker Hub Images Scraper — Repository Metadata, Pull Counts, and Image Tags

![Docker Hub Images Scraper cover](https://images.bigibyte.com/cdn-cgi/image/width=1260,height=540,fit=cover,format=webp/apify-actors-covers/docker-hub-images-scraper-cover.png)

### Overview

Docker Hub Images Scraper collects publicly available Docker image and repository information for research, inventory management, and development workflows.

Choose a collection mode to search repositories, retrieve repository details, or collect image tags. Configure the maximum number of records and export structured results in JSON, CSV, Excel, or other supported dataset formats.

### Features

- **Repository Search:** Find Docker repositories matching a search query.
- **Repository Details:** Collect metadata for specified repositories.
- **Tag Collection:** Retrieve available tags for selected images.
- **Pull Statistics:** Capture repository pull counts when available.
- **Popularity Metrics:** Collect repository star counts.
- **Official Image Identification:** Identify official images when this information is available.
- **Configurable Collection:** Set record limits to control dataset size.
- **Structured Exports:** Prepare repository information for spreadsheets and data analysis.

### Collection Modes

#### 1. Search Repositories

Search for repositories using a keyword or phrase. Results can include repository names, descriptions, popularity metrics, and available ownership information.

#### 2. Repository Details

Collect detailed metadata for specified repositories, such as `library/python`.

#### 3. Image Tags

Retrieve available tags for selected repositories. Each tag record identifies the repository and its associated tag.

### Use Cases

- **Image Inventory:** Maintain a structured inventory of Docker images and their metadata.
- **Popularity Analysis:** Compare repository star counts and pull statistics.
- **Official Image Research:** Distinguish official images from community-maintained repositories when the relevant metadata is available.
- **Tag Audits:** Review available image tags for development and deployment workflows.
- **Repository Discovery:** Find images relevant to Python, databases, web servers, and other technologies.
- **Dataset Monitoring:** Collect recurring snapshots to compare repository metadata over time.

### Input Parameters

| Parameter | Type | Default | Description |
|---|---|---|---|
| `mode` | String | `search` | Selects `search`, `details`, or `tags` collection mode. |
| `query` | String | Empty | Search term used to find repositories. |
| `repositories` | Array | `[]` | Repository names to inspect, such as `library/python`. |
| `maxItems` | Integer | `100` | Maximum number of records to save, up to the actor's configured limit. |
| `requestDelaySecs` | Number | `1` | Configured delay between requests, where applicable. |
| `timeoutSecs` | Integer | `300` | Overall run time limit in seconds. |
| `requestTimeoutSecs` | Integer | `30` | Maximum waiting time for an individual request, in seconds. |

### Example Input

```json id="7jv4qn"
{
  "mode": "search",
  "query": "python",
  "repositories": ["library/python"],
  "maxItems": 50,
  "requestDelaySecs": 1,
  "timeoutSecs": 300,
  "requestTimeoutSecs": 30
}
```

This configuration searches for Python-related repositories and saves up to 50 matching records.

### What Data Does This Actor Extract?

The actor collects repository metadata and, depending on the selected mode, repository details or image tag information.

#### Extracted Data Fields

| Field | Description |
|---|---|
| `repo_name` | Repository name. |
| `short_description` | Short description of the repository. |
| `star_count` | Number of stars, when available. |
| `pull_count` | Total pull count, when available. |
| `repo_owner` | Repository owner or namespace, when available. |
| `is_automated` | Indicates whether the repository is marked as automated, when available. |
| `is_official` | Indicates whether the repository is identified as official, when available. |
| `namespace` | Namespace associated with the repository, when available. |
| `name` | Repository or image name, depending on the collection mode. |
| `tag` | Image tag, when collecting tags. |
| `scraped_at` | Date and time when the record was collected. |

The available fields depend on the collection mode and the metadata returned for each repository or tag.

### Example Output

The following is an illustrative repository search record.

```json id="m4z8pk"
{
  "repo_name": "python",
  "short_description": "Python is an interpreted, interactive, object-oriented, open-source programming language.",
  "star_count": 10535,
  "pull_count": 9373865365,
  "repo_owner": "",
  "is_automated": false,
  "is_official": true,
  "scraped_at": "2026-10-26T00:00:00+00:00"
}
```

Actual values and available fields may vary depending on the repository and collection mode.

### Working with Your Dataset

After collection, review the dataset in Apify and export the results in a suitable format.

- **JSON:** Use structured repository records in scripts and data-processing applications.
- **CSV:** Compare repository names, pull counts, and star counts in spreadsheet software.
- **Excel:** Create image inventories, repository comparisons, and tag audit reports.
- **Other supported formats:** Choose from the dataset export formats available in Apify.

### Important Notes

- Select the collection mode that matches your needs: repository search, repository details, or image tags.
- Repository names should identify the intended namespace and image where required.
- The `maxItems` parameter controls the maximum number of saved records.
- Some metadata fields may be absent for particular repositories or collection modes.
- Pull counts, star counts, and available tags can change over time.
- Collected information represents the metadata available during the run.

### FAQ

**Who is this actor for?**

It is designed for developers, DevOps engineers, security researchers, and analysts who need structured Docker image and repository metadata.

**Can I search for repositories by keyword?**

Yes. Use the `search` mode and provide a search term through `query`.

**Can I collect details for specific repositories?**

Yes. Provide repository names through `repositories` and select the `details` mode.

**Can I collect image tags?**

Yes. Select the `tags` mode and provide the repositories you want to inspect.

**What export formats are supported?**

You can export collected records as JSON, CSV, Excel, and other formats supported by Apify datasets.

**Can I schedule recurring collections?**

Yes. Configure an Apify schedule to refresh repository metadata or image tags at your preferred interval.

### Disclaimer

This actor is an independent tool and is not affiliated with, endorsed by, sponsored by, or officially associated with Docker Hub, Docker, Inc., or their owners. The collected information is provided for research and informational purposes. Users are responsible for ensuring that their collection and use of data comply with applicable laws and relevant terms.

### Is Web Scraping Legal?

Collecting information that is already public is generally legal. There is no single law that bans all forms of web scraping. The limits are the usual ones: do not break into accounts, do not take private or confidential data, and be careful with personal data and copyrighted works. A site's terms can also restrict how you access it. Facts such as a public name, price, or rating are not the same thing as republishing someone's article or photo.

This actor collects information from public pages. It does not log in and it does not bypass access controls.

For a longer explanation, see Apify's article [Is web scraping legal?](https://blog.apify.com/is-web-scraping-legal/).

# Actor input Schema

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

What to scrape.

## `query` (type: `string`):

Search query used in search mode.

## `repositories` (type: `array`):

Repositories as namespace/name for repo and tags modes.

## `maxItems` (type: `integer`):

Stop after this many successful rows. Hard max is 1000.

## `requestDelaySecs` (type: `number`):

Seconds to wait between requests.

## `userAgent` (type: `string`):

User-Agent header sent with each request.

## `timeoutSecs` (type: `integer`):

Overall run budget in seconds.

## `requestTimeoutSecs` (type: `integer`):

Per-request timeout in seconds.

## `proxyConfiguration` (type: `object`):

Optional proxy. Leave off unless you need it.

## Actor input object example

```json
{
  "mode": "search",
  "query": "python",
  "repositories": [
    "library/python"
  ],
  "maxItems": 100,
  "requestDelaySecs": 1,
  "userAgent": "ActorResearch/1.0",
  "timeoutSecs": 300,
  "requestTimeoutSecs": 30,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `overview` (type: `string`):

Dataset rows in the overview table.

## `dataset` (type: `string`):

Full dataset for this run.

## `items` (type: `string`):

Dataset items as JSON.

# 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 = {
    "repositories": [
        "library/python"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("zerobreak/docker-hub-images-scraper").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 = { "repositories": ["library/python"] }

# Run the Actor and wait for it to finish
run = client.actor("zerobreak/docker-hub-images-scraper").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 '{
  "repositories": [
    "library/python"
  ]
}' |
apify call zerobreak/docker-hub-images-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,zerobreak/docker-hub-images-scraper"
        }
    }
}
```

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/JWhs7BlJpmtj7ejbO/builds/GpUJYf14bYJHxUVz8/openapi.json
