IP2WHOIS Hosted Domain API

Lists the domain names hosted on a given IP address, offered as part of IP2Location.io.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 1

GET /domains List domains hosted on an IP address #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/ip2location:hosted-domain"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

ip2location-hosted-domain-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: IP2WHOIS Hosted Domain API
  summary: Hosted Domain
  description: |-
    IP2WHOIS Hosted Domain API returns the domain names hosted on an IP address, in real time, for IPv4 and IPv6.

    **Authentication.** Send your API key as a Bearer token in the `Authorization` header (recommended), or as the `key` query parameter. This endpoint requires an API key.

    **Pagination.** Results are returned 100 domains at a time on the Security plan (1 on Free, 5 on Starter, 20 on Plus). Read `total_pages` from the first response and request each `page` in turn until every page has been read.

    The endpoint supports JSON and XML responses.
  version: 1.0.0
  termsOfService: https://www.ip2location.io/terms-of-service
  contact:
    name: IP2Location.io
    url: https://www.ip2location.io
    email: support@ip2location.io
  license:
    name: MIT
    url: https://github.com/ip2location/ip2location-io-openapi/blob/main/LICENSE
servers:
  - url: https://domains.ip2whois.com
    description: Hosted Domain endpoint.
tags:
  - name: Hosted Domain
    description: List the domain names hosted on an IP address.
paths:
  /domains:
    get:
      tags:
        - Hosted Domain
      summary: List domains hosted on an IP address
      description: Returns one page of domain names hosted on the address. Use `page` to walk the result set until `total_pages` is reached.
      operationId: hostedDomain
      externalDocs:
        description: Hosted Domain API documentation
        url: https://www.ip2location.io/ip2whois-domains-documentation
      parameters:
        - $ref: '#/components/parameters/key_required'
        - $ref: '#/components/parameters/ip_required'
        - $ref: '#/components/parameters/format_json_xml'
        - $ref: '#/components/parameters/page'
      responses:
        '200':
          description: One page of hosted domains.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HostedDomainResponse'
              examples:
                Hosted Domain:
                  value:
                    ip: 8.8.8.8
                    total_domains: 3857
                    page: 1
                    per_page: 100
                    total_pages: 39
                    domains:
                      - 000180.top
                      - 00100tet.xyz
                      - 001hash.vip
            application/xml:
              schema:
                type: string
                description: XML representation of the same fields as the JSON response, with a root `<result>` element.
              example: |-
                <result>
                  <ip>8.8.8.8</ip>
                  <total_domains>3857</total_domains>
                  <page>1</page>
                  <per_page>100</per_page>
                  <total_pages>39</total_pages>
                  <domains>
                    <item>000180.top</item>
                    <item>00100tet.xyz</item>
                    <item>001hash.vip</item>
                  </domains>
                </result>
        '400':
          description: Missing parameter, invalid IP address, invalid format, or invalid page value.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                Missing parameter:
                  value:
                    error:
                      error_code: 10000
                      error_message: Missing parameter.
                Invalid IP address:
                  value:
                    error:
                      error_code: 10006
                      error_message: Invalid IP address.
                Invalid format:
                  value:
                    error:
                      error_code: 10007
                      error_message: Invalid format.
                Invalid page value:
                  value:
                    error:
                      error_code: 10008
                      error_message: Invalid page value.
        '401':
          description: API key not found, disabled, expired, or out of queries.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                API key not found:
                  value:
                    error:
                      error_code: 10001
                      error_message: API key not found.
                API key disabled:
                  value:
                    error:
                      error_code: 10002
                      error_message: API key disabled.
                API key expired:
                  value:
                    error:
                      error_code: 10003
                      error_message: API key expired.
                Insufficient queries:
                  value:
                    error:
                      error_code: 10004
                      error_message: Insufficient queries.
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                Internal server error:
                  value:
                    error:
                      error_code: 10005
                      error_message: Internal server error.
      security:
        - bearerAuth: []
        - apiKey: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'API key sent as `Authorization: Bearer {YOUR_API_KEY}`. This is the recommended method because it keeps the key out of URLs, logs and browser history.'
    apiKey:
      type: apiKey
      in: query
      name: key
      description: API key sent as the `key` query parameter. Supported as an alternative to the Bearer token, but less secure because the key appears in the URL.
  parameters:
    key_required:
      name: key
      in: query
      required: false
      schema:
        type: string
      description: 'API key. Optional when the key is sent as an `Authorization: Bearer` token. Get a free key at https://www.ip2location.io/sign-up.'
    ip_required:
      name: ip
      in: query
      required: true
      schema:
        type: string
        format: ip
        example: 8.8.8.8
      description: IPv4 or IPv6 address to look up.
    format_json_xml:
      name: format
      in: query
      required: false
      schema:
        type: string
        enum:
          - json
          - xml
        default: json
      description: Response format. Defaults to `json`.
    page:
      name: page
      in: query
      required: false
      schema:
        type: integer
        minimum: 1
        default: 1
        example: 1
      description: Page of hosted domains to return. Increment it until `total_pages` is reached. Defaults to the first page.
  schemas:
    ErrorResponse:
      type: object
      description: Error envelope returned for every failed request.
      required:
        - error
      properties:
        error:
          type: object
          required:
            - error_code
            - error_message
          properties:
            error_code:
              type: integer
              description: Numeric error code, unique within the API.
              example: 10001
            error_message:
              type: string
              description: Human-readable error message.
              example: Invalid IP address.
    HostedDomainResponse:
      type: object
      description: One page of domain names hosted on the requested address.
      required:
        - ip
        - domains
      properties:
        ip:
          type: string
          format: ip
          description: IP address that was looked up.
          example: 8.8.8.8
        total_domains:
          type: integer
          description: Total number of hosted domains found for the address.
          example: 3857
        page:
          type: integer
          minimum: 1
          description: Current page number.
          example: 1
        per_page:
          type: integer
          description: 'Number of domains returned per page. Free: 1, Starter: 5, Plus: 20, Security: 100.'
          example: 100
        total_pages:
          type: integer
          description: Total number of pages for the address.
          example: 39
        domains:
          type: array
          description: Domain names hosted on the address, one page at a time.
          items:
            type: string
            example: 000180.top
          example:
            - 000180.top
            - 00100tet.xyz
            - 001hash.vip
x-provenance:
  method: harvested
  publisher: IP2Location
  source: https://raw.githubusercontent.com/ip2location/ip2location-io-openapi/main/json/HostedDomain.json
  note: split by refine-openapis from the provider's own published document, verified by fetch (openapi/_original/*.fetch.json);
    stamped by stamp-openapi-provenance.py (roadmap#793)