Domain WHOIS / registration data

GET https://api.api.sh/web/v1/whois
1 credit / call web data try it in the playground →

Registration data of a domain from its registry, the way WHOIS shows it: registered, updated and expiry dates, age and days until expiry, status codes, registrar (name, IANA id, website, abuse email and phone), name servers, DNSSEC (signed, DS records), the registry's WHOIS server and every event. For gTLDs and most ccTLDs the registry's structured data is used, merged with the registrar's own record; for registries without it (.io, .de, .jp, .co and others) their WHOIS server is read and parsed. A subdomain is resolved to its registered name (www.example.co.uk -> example.co.uk). Unregistered names answer registered: false. Contacts keep only organization, state and country (names, emails, phones and addresses of people are never returned). raw=true adds the registry's record (or the WHOIS text without personal contact lines).

Every response includes credits_used: the credits this call cost.

Parameters

nametypedescription
domainrequired string Domain name (a URL or subdomain works too). Example: github.com
raw boolean Also return the registry's full record (raw) or WHOIS text (raw_text). Example: false Default: false
registrar_lookup boolean Also read the registrar's own record (thin registries such as .com/.net). Default true. Default: true

Every endpoint also takes fresh, raw, fields (see lean responses and caching).

Example

curl "https://api.api.sh/web/v1/whois?domain=github.com" \
  -H "x-api-key: $APISH_KEY"

Response

A JSON object with the fields described above, plus raw (the source's own data), cached, fetched_at and credits_used. Errors return {"success": false, "error": "…"} with the HTTP status (see errors). A lookup that ran but found nothing (404) costs the price above; refused calls and errors on our side are free (what's charged).

The fastest way to see the full response is the playground: it runs this endpoint with your account and shows the exact JSON.