Public APIs
Lightweight JSON APIs for developers. All endpoints use GET, support cross-origin requests, and require no API key.
Public IP and location
Get the caller’s public IP and Cloudflare’s approximate location, timezone, and network information.
/api/v1/ipSource: Cloudflare request metadata·Not cached. Location is an IP-based estimate, not GPS.
DNS lookup
Look up common DNS records, including A, AAAA, CNAME, MX, NS, and TXT.
/api/v1/dns?name=example.com&type=A- name *
- Fully qualified domain name, such as example.com.
- type
- Record type. Defaults to A.
Source: Cloudflare DNS over HTTPS·Successful responses are cached for 60 seconds.
Weather forecast
Get the nearest forecast and up to 24 hourly forecast points by coordinates.
/api/v1/weather?lat=31.23&lon=121.47- lat *
- Latitude, from -90 to 90.
- lon *
- Longitude, from -180 to 180.
Source: MET Norway·Coordinates are rounded to about 1 km; responses are cached for 5 minutes. Data is CC BY 4.0 with attribution.
Service status summary
Read official status and published incident summaries for OpenAI, Claude, Cloudflare, GitHub, and more.
/api/v1/statusSource: Official status pages·Responses are cached for 60 seconds; some upstream results may be the latest successful snapshot.
Usage notes
Keep request rates reasonable. Weather and DNS endpoints rely on third-party data sources, so results may be affected by upstream availability and cache duration. IP locations are estimates.
Weather data comes from MET Norway. If you republish it, retain the source attribution, license link, and notice of modifications.