# URLScan.io API reference

> The urlscan.io API submits a URL to be loaded in a headless Chrome browser and returns what happened: every HTTP request and response, the domains, IPs, ASNs, certificates and hashes contacted, the page's server, location and TLS details, a screenshot, the DOM and urlscan's verdicts. Its search…

Source: https://osinttools.io/apis/urlscan/ (Markdown view of an OSINTtools.io page; append `.md` to any page URL for this format).

Compiled by OSINTtools.io editors from the vendor's docs, updated Nov 29, 2026. Listing: https://osinttools.io/tools/urlscan/

- Base URL: https://urlscan.io
- Authentication: API key in the `API-Key` header. Get a key: https://urlscan.io/user/signup Create the key under Settings & API.
- Free tier: yes
- Pricing: Subscription
- Rate limits: Each action (search, public, unlisted and private scans, result retrieval) has its own per-minute, per-hour and per-day limit, which depend on your account; read yours from GET /api/v1/quotas. Windows reset at the full minute, the full hour and midnight UTC, and only successful (200) requests count.
- Vendor docs: https://docs.urlscan.io/apis/urlscan-openapi
- OpenAPI spec: https://docs.urlscan.io/_bundle/apis/urlscan-openapi.yaml
- Python SDK: urlscan-python, https://github.com/urlscan/urlscan-python

## Overview

The urlscan.io API submits a URL to be loaded in a headless Chrome browser and returns what happened: every HTTP request and response, the domains, IPs, ASNs, certificates and hashes contacted, the page's server, location and TLS details, a screenshot, the DOM and urlscan's verdicts. Its search finds earlier scans by domain, IP, ASN, hash and other fields.

An investigator uses it to see where a suspicious link leads and what it loads without opening it themselves, and to search past scans for a domain or IP. Submitting a scan makes urlscan's browser visit the URL (active); search and result retrieval read stored scans (passive). Scans are **public** by default and then show up in everyone's search: use `unlisted` or `private` visibility for anything sensitive.

Calls go to `https://urlscan.io` with your key in the `API-Key` header (create one under Settings & API after signing up). Submit with POST /api/v1/scan, wait, then poll GET /api/v1/result/{scanId}/, which answers 404 until the scan has finished. Unauthenticated requests get only minor quotas, and free users may be limited to recent history in search; some data sources (hostnames, malicious-observable lookups) need urlscan Pro.

## Errors

| Status | Meaning |
| --- | --- |
| 400 | Request not accepted: blocked or spammy URL, invalid hostname or scheme, missing url, basic-auth credentials in the URL, a hostname that does not resolve, or a validation error |
| 404 | Result not available yet: the scan has not finished |
| 429 | Rate limit or quota for that action exceeded |

## Scanning

### Submit a URL to be scanned in urlscan's browser

`POST /api/v1/scan`

- Takes: URL
- Footprint: active (contacts the target)

urlscan's headless browser loads the URL, so the target is contacted. Returns the scan's UUID; fetch the result with GET /api/v1/result/{scanId}/ once it finishes. Visibility defaults to public, which makes the scan searchable by anyone.

Response fields:

- `uuid` (string): UUID of the scan result (the scanId)
- `country` (string): Country the scan runs from
- `visibility` (string): Visibility given to the scan
- `url` (string): URL being scanned

```bash
curl -X POST 'https://urlscan.io/api/v1/scan' \
  -H 'API-Key: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"url":"https://example.com/login","visibility":"unlisted","country":"de","tags":["phishing"]}'
```

Example response (200):

```json
{
  "uuid": "0b7c6f2e-1a2b-4c3d-9e8f-123456789abc",
  "visibility": "unlisted",
  "url": "https://example.com/login",
  "country": "de"
}
```

### Get a finished scan: requests, contacted hosts, page details, lists and verdicts

`GET /api/v1/result/{scanId}/`

- Footprint: passive (the target is not contacted)

Returns 404 until the scan has finished. The docs suggest waiting at least 10 seconds, then polling every 2 seconds with an upper timeout. The full result is large: `data` holds every request and response, cookies and console logs; `lists` aggregates IPs, domains, URLs, ASNs, certificates and hashes.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `scanId` | path | string | yes | UUID of the scan result Example: 0b7c6f2e-1a2b-4c3d-9e8f-123456789abc |

Response fields:

- `task.uuid` (string): Scan ID
- `task.time` (string): When the scan was created
- `task.url` (string): URL that was submitted
- `task.visibility` (string): public, unlisted or private
- `task.screenshotURL` (string): Link to the screenshot
- `page.url` (string): Final URL after redirects
- `page.domain` (string): Hostname of the final URL
- `page.ip` (string): IP contacted for the main page
- `page.asn` (string): AS number of that IP
- `page.country` (string): GeoIP country of that IP
- `page.title` (string): Page title
- `page.tlsIssuer` (string): Issuer of the page's TLS certificate
- `page.domainAgeDays` (integer): Age of the domain in days at scan time
- `lists.ips[]` (string): IPs contacted
- `lists.domains[]` (string): Hostnames contacted
- `lists.urls[]` (string): URLs requested
- `lists.hashes[]` (string): SHA256 hashes of response bodies
- `verdicts.overall.score` (integer): -100 (benign) to 100 (malicious)
- `verdicts.overall.malicious` (boolean): Overall malicious verdict
- `verdicts.overall.categories[]` (string): Categories such as phishing
- `data.requests[]` (object): Every HTTP transaction during the page load

```bash
curl 'https://urlscan.io/api/v1/result/0b7c6f2e-1a2b-4c3d-9e8f-123456789abc/' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200, Trimmed):

```json
{
  "task": {
    "uuid": "0b7c6f2e-1a2b-4c3d-9e8f-123456789abc",
    "time": "2026-11-28T10:00:00.000Z",
    "url": "https://example.com/login",
    "domain": "example.com",
    "apexDomain": "example.com",
    "visibility": "unlisted",
    "method": "api",
    "screenshotURL": "https://urlscan.io/screenshots/0b7c6f2e-1a2b-4c3d-9e8f-123456789abc.png",
    "domURL": "https://urlscan.io/dom/0b7c6f2e-1a2b-4c3d-9e8f-123456789abc/",
    "tags": [
      "phishing"
    ]
  },
  "page": {
    "url": "https://www.example.com/login",
    "domain": "www.example.com",
    "apexDomain": "example.com",
    "country": "NL",
    "server": "nginx",
    "ip": "203.0.113.7",
    "asn": "AS64500",
    "asnname": "EXAMPLE-AS, NL",
    "title": "Sign in",
    "mimeType": "text/html",
    "status": "200",
    "domainAgeDays": 12,
    "tlsIssuer": "Example CA",
    "tlsValidDays": 89
  },
  "lists": {
    "ips": [
      "203.0.113.7"
    ],
    "countries": [
      "NL"
    ],
    "asns": [
      "64500"
    ],
    "domains": [
      "www.example.com"
    ],
    "urls": [
      "https://www.example.com/login"
    ],
    "hashes": [
      "9f2c1d4e5b6a7c8d9e0f1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b1c2d"
    ]
  },
  "verdicts": {
    "overall": {
      "score": 100,
      "categories": [
        "phishing"
      ],
      "brands": [],
      "tags": [],
      "malicious": true,
      "hasVerdicts": true
    }
  },
  "stats": {
    "uniqIPs": 1,
    "uniqCountries": 1
  }
}
```

### Download the screenshot of a finished scan (PNG)

`GET /screenshots/{scanId}.png`

- Footprint: passive (the target is not contacted)

Available once the scan has finished.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `scanId` | path | string | yes | UUID of the scan result Example: 0b7c6f2e-1a2b-4c3d-9e8f-123456789abc |

```bash
curl 'https://urlscan.io/screenshots/0b7c6f2e-1a2b-4c3d-9e8f-123456789abc.png' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200, image/png):

```
(binary PNG image)
```

### Download the DOM snapshot of a finished scan (text)

`GET /dom/{scanId}/`

- Footprint: passive (the target is not contacted)

The page's DOM as the browser saw it, as plain text. Available once the scan has finished.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `scanId` | path | string | yes | UUID of the scan result Example: 0b7c6f2e-1a2b-4c3d-9e8f-123456789abc |

```bash
curl 'https://urlscan.io/dom/0b7c6f2e-1a2b-4c3d-9e8f-123456789abc/' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200, text/plain):

```
<html><head><title>Sign in</title></head><body><form action="/session">...</form></body></html>
```

## Search

### Search past scans by domain, IP, ASN, hash and other fields (Elasticsearch query string)

`GET /api/v1/search`

- Takes: Domain, IP address, URL
- Footprint: passive (the target is not contacted)

Finds public scans by anyone plus your own unlisted and private scans. `total` is exact up to 10,000. To page, pass the `sort` value of the last result as `search_after`, and stop when a call returns fewer than `size` results (not when has_more is false). Unauthenticated and free users may be limited to recent history; the response then includes `search_date_limit_days`. Some data sources and fields are urlscan Pro only.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `q` | query | string | no | Search query (Elasticsearch query string), e.g. page.domain:example.com or page.ip:203.0.113.7 Example: page.domain:example.com |
| `size` | query | integer | no | Number of results to return (max 10000) Example: 100 |
| `search_after` | query | string | no | The sort value of the last (oldest) result from the previous call, comma-separated Example: 1795860000000,0b7c6f2e-1a2b-4c3d-9e8f-123456789abc |
| `datasource` | query | string | no | Data source: scans, or (urlscan Pro) hostnames, incidents, notifications, certificates Example: scans One of: scans, hostnames, incidents, notifications, certificates |
| `collapse` | query | string | no | Field to collapse results on (current page only) Example: page.domain.keyword |

Response fields:

- `results[].task.uuid` (string): Scan ID
- `results[].task.url` (string): Submitted URL
- `results[].task.time` (string): When it was scanned
- `results[].page.url` (string): Final URL
- `results[].page.domain` (string): Final hostname
- `results[].page.ip` (string): Server IP
- `results[].page.asn` (string): Server ASN
- `results[].verdicts.malicious` (boolean): Malicious verdict
- `results[].result` (string): API link to the full result
- `results[].screenshot` (string): Screenshot link
- `results[].sort[]` (string): Value to pass as search_after
- `total` (integer): Number of results (capped at 10,000)
- `took` (integer): Query time in ms
- `has_more` (boolean): True when more than 10,000 results exist
- `search_date_limit_days` (integer): How far back the search goes, when limited

```bash
curl 'https://urlscan.io/api/v1/search' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200):

```json
{
  "results": [
    {
      "task": {
        "visibility": "public",
        "method": "api",
        "domain": "example.com",
        "apexDomain": "example.com",
        "time": "2026-11-27T09:26:20.465Z",
        "uuid": "5d1e2f3a-4b5c-4d6e-8f70-81a2b3c4d5e6",
        "url": "https://example.com/"
      },
      "page": {
        "country": "DE",
        "server": "nginx",
        "ip": "192.0.2.44",
        "mimeType": "text/html",
        "title": "Example Domain",
        "url": "https://example.com/",
        "domain": "example.com",
        "apexDomain": "example.com",
        "asnname": "EXAMPLE-NET, DE",
        "asn": "AS64501",
        "status": "200"
      },
      "verdicts": {
        "score": 0,
        "malicious": false,
        "hasVerdicts": false
      },
      "sort": [
        1795771580465,
        "5d1e2f3a-4b5c-4d6e-8f70-81a2b3c4d5e6"
      ],
      "result": "https://urlscan.io/api/v1/result/5d1e2f3a-4b5c-4d6e-8f70-81a2b3c4d5e6/",
      "screenshot": "https://urlscan.io/screenshots/5d1e2f3a-4b5c-4d6e-8f70-81a2b3c4d5e6.png"
    }
  ],
  "total": 1,
  "took": 23,
  "has_more": false
}
```

## Pro lookups

### Historical observations of a hostname: certificate logs, scans, passive DNS, zone files (Pro)

`GET /api/v1/hostname/{hostname}`

- Takes: Domain
- Footprint: passive (the target is not contacted)
- Plan: urlscan Pro

Returns observations of the hostname from the Hostnames data source with first and last seen dates. If `pageState` is set in the response, repeat the call with it for more. urlscan Pro.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `hostname` | path | string | yes | The hostname to query Example: www.example.com |
| `limit` | query | integer | no | Return at most this many results (10 to 10000) Example: 100 |
| `pageState` | query | string | no | Page state from the previous call, to get more results Example: AbCdEf123 |

Response fields:

- `results[].seen_on` (string): Date (YYYY-MM-DD)
- `results[].source` (string): ct, scan, pdns, zonefile, scan-link or scan-cert-subject
- `results[].sub_id` (string): Observation value, can be empty
- `results[].first_seen` (string): First seen (ISO 8601)
- `results[].last_seen` (string): Last seen (ISO 8601)
- `results[].data` (object): Additional JSON for the record, when data_type is json
- `pageState` (string): Set when more results are available

```bash
curl 'https://urlscan.io/api/v1/hostname/www.example.com' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200):

```json
{
  "results": [
    {
      "seen_on": "2026-11-20",
      "source": "ct",
      "sub_id": "",
      "first_seen": "2026-10-02T11:20:15.617Z",
      "last_seen": "2026-11-20T16:09:09.591Z",
      "data_type": null,
      "data": null
    },
    {
      "seen_on": "2026-11-18",
      "source": "pdns",
      "sub_id": "",
      "first_seen": "2026-10-03T08:00:00.000Z",
      "last_seen": "2026-11-18T08:00:00.000Z",
      "data_type": null,
      "data": null
    }
  ]
}
```

### How often an IP, hostname, domain or URL was seen in malicious scans, with first and last seen (Pro)

`GET /api/v1/malicious/{type}/{value}`

- Takes: IP address, Domain, URL
- Footprint: passive (the target is not contacted)
- Plan: urlscan Pro

`domain` matches the apex domain and all its subdomains; `hostname` matches one exact host; `url` must be URL-encoded. urlscan Pro.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `type` | path | string | yes | Kind of observable Example: domain One of: ip, hostname, domain, url |
| `value` | path | string | yes | The observable; a URL must be URL-encoded Example: example.com |

Response fields:

- `observable` (string): The value looked up
- `type` (string): ip, hostname, domain or url
- `count` (integer): Times seen in malicious scan results
- `firstSeen` (string): First seen in malicious results, or null
- `lastSeen` (string): Last seen in malicious results, or null

```bash
curl 'https://urlscan.io/api/v1/malicious/domain/example.com' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200):

```json
{
  "observable": "example.com",
  "type": "domain",
  "count": 3,
  "firstSeen": "2026-09-01T12:00:00.000Z",
  "lastSeen": "2026-11-25T07:30:00.000Z"
}
```

## Account

### List the countries scans can be run from

`GET /api/v1/availableCountries`

- Footprint: passive (the target is not contacted)

Values for the `country` field of a scan submission.

Response fields:

- `countries[]` (string): Country code

```bash
curl 'https://urlscan.io/api/v1/availableCountries' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200):

```json
{
  "countries": [
    "de",
    "us",
    "jp"
  ]
}
```

### Your limits and usage for each action, per minute, hour and day

`GET /api/v1/quotas`

- Footprint: passive (the target is not contacted)

Returns, for each action (private, public, retrieve, search and others), the limit, used, remaining and percent for the day, hour and minute.

Response fields:

- `scope` (string): Scope of the limits (e.g. team)
- `limits.{action}.{window}.limit` (integer): Maximum for that window
- `limits.{action}.{window}.used` (integer): Used in that window
- `limits.{action}.{window}.remaining` (integer): Remaining in that window
- `limits.{action}.{window}.percent` (number): Percentage used

```bash
curl 'https://urlscan.io/api/v1/quotas' \
  -H 'API-Key: YOUR_API_KEY'
```

Example response (200):

```json
{
  "scope": "user",
  "limits": {
    "public": {
      "day": {
        "limit": 1000,
        "used": 12,
        "remaining": 988,
        "percent": 1
      },
      "hour": {
        "limit": 100,
        "used": 2,
        "remaining": 98,
        "percent": 2
      },
      "minute": {
        "limit": 10,
        "used": 0,
        "remaining": 10,
        "percent": 0
      }
    }
  }
}
```

---

Listings on OSINTtools.io are reviewed by editors and re-verified on a schedule; check pricing and availability on the vendor's site before relying on them, and use OSINT tools only with a lawful basis.
Site index for agents: https://osinttools.io/llms.txt · Full catalog: https://osinttools.io/llms-full.txt · MCP server (Streamable HTTP, no auth): https://osinttools.io/mcp/
