---
updatedAt: 2025-06-05T21:08:18.000Z
agentTools:
  projectIndex: https://docs.securitytrails.com/llms.txt
---

# Explore IPs

Returns the neighbors in any given IP level range and essentially allows you to explore closeby IP addresses.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "SecurityTrails API",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.securitytrails.com/v1"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/ips/nearby/{ipaddress}": {
      "get": {
        "summary": "Explore IPs",
        "description": "Returns the neighbors in any given IP level range and essentially allows you to explore closeby IP addresses.",
        "operationId": "explore-ips-old",
        "parameters": [
          {
            "name": "ipaddress",
            "in": "path",
            "description": "Starting IP address (optionally with CIDR subnet mask)",
            "schema": {
              "type": "string",
              "default": "8.8.8.8"
            },
            "required": true
          },
          {
            "name": "apikey",
            "in": "query",
            "description": "Your SecurityTrails API key. See [authentication documentation](doc:authentication)",
            "required": true,
            "schema": {
              "type": "string",
              "default": "your_api_key"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"blocks\": [\n    {\n      \"ip_count\": 3,\n      \"ip\": \"1.1.1.0/32\"\n    },\n    {\n      \"ip_count\": 19247,\n      \"ip\": \"1.1.1.1/32\",\n      \"current\": true\n    },\n    {\n      \"ip_count\": 64,\n      \"ip\": \"1.1.1.2/32\"\n    },\n    {\n      \"ip_count\": 13,\n      \"ip\": \"1.1.1.3/32\"\n    },\n    {\n      \"ip_count\": 6,\n      \"ip\": \"1.1.1.4/32\"\n    },\n    {\n      \"ip_count\": 7,\n      \"ip\": \"1.1.1.5/32\"\n    },\n    {\n      \"ip_count\": 2,\n      \"ip\": \"1.1.1.6/32\"\n    },\n    {\n      \"ip_count\": 2,\n      \"ip\": \"1.1.1.7/32\"\n    },\n    {\n      \"ip_count\": 2,\n      \"ip\": \"1.1.1.8/32\"\n    },\n    {\n      \"ip_count\": 3,\n      \"ip\": \"1.1.1.9/32\"\n    },\n    {\n      \"ip_count\": 5,\n      \"ip\": \"1.1.1.10/32\"\n    },\n    {\n      \"sites\": 13,\n      \"ip\": \"1.1.1.11/32\"\n    },\n    {\n      \"ip_count\": 332,\n      \"ip\": \"1.1.1.12/32\"\n    },\n    {\n      \"ip_count\": 0,\n      \"ip\": \"1.1.1.13/32\"\n    },\n    {\n      \"ip_count\": 0,\n      \"ip\": \"1.1.1.14/32\"\n    },\n    {\n      \"ip_count\": 0,\n      \"ip\": \"1.1.1.15/32\"\n    }\n  ]\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "blocks": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "ip_count": {
                            "type": "integer",
                            "example": 3,
                            "default": 0
                          },
                          "ip": {
                            "type": "string",
                            "example": "1.1.1.0/32"
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"message\": \"The IP mask is not supported\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "The IP mask is not supported"
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  }
}
```