Account breaches

Get all breached account hashes for a range

Changed on

Available on Pro and High RPM subscriptions. Search breached addresses via k-anonymity by providing the first 6 characters of the SHA-1 hash of a normalised email address. Trim leading and trailing whitespace and lowercase the email address before hashing its UTF-8 bytes. The response contains matching hash suffixes and associated breach names after public filtering. Sensitive and retired breaches are not returned. Per the terms of use, any results that do not match the target address being searched must be discarded immediately and not stored or further processed.

For example, SHA-1 of multiple-breaches@hibp-integration-tests.com is 6B5917C6C0AADE0C085843D66E4944E108C4A4CD. Request prefix 6B5917, then look for suffix C6C0AADE0C085843D66E4944E108C4A4CD in the response. This example still requires a subscription with hash-range access. See the test account reference.

get/breachedaccount/range/{prefix}

Request

  • Base URL
    https://haveibeenpwned.com/api/v3
  • Auth
    API key in header hibp-api-key

Path parameters

prefixstring required

First 6 characters of the SHA-1 hash of the email address to search for (hexadecimal, not case-sensitive)

Headers

user-agentstring required

User agent identifying the consuming application. Required for authenticated APIs. Use your application name and optionally its version. Browsers may supply their own User-Agent instead of a custom value.

Response

Hash suffixes and breach names for addresses in the requested range. Sensitive breaches are removed and any suffix with no remaining public breaches is omitted.

hashSuffixstring required

The remaining 34 hexadecimal characters of the breached account's SHA-1 hash.

websitesstring[] required

The breach names associated with the hashed account suffix after public API filtering. Sensitive breaches are never returned.

Changes

    • breaking

      removed the media type application/json for the response with the status

    • info

      the items/hashSuffix response's property pattern ^[0-9A-Fa-f]{34}$ was added for the status

    • info

      api operation id getAccountBreachRange was added

    1 more change in this revision