Skip to content

Look up domain WHOIS

GET /api/v2/whois

Looks up the public WHOIS record of a domain: registrar, nameservers, dates, registry status codes and DNSSEC. The domain does not have to be in your account. To see whether a name can be registered and what it costs, use GET /api/v2/domains/availability instead. Answers are cached for 5 minutes. A change at the registry can take that long to show. Add sourceText=true to get the raw WHOIS text as well.

Authentication: An API key with the scope read:domains. About keys and scopes

Request

Query parameters

domainstringrequired
Domain name to look up, such as example.com. A URL is cut down to its host name. Internationalized names are converted to punycode.
sourceTextboolean
Set to true to include the raw WHOIS text in sourceText. Default false. Default false.

Example

GET /api/v2/whois
curl "https://cloud.hostup.se/api/v2/whois?domain=example.com" \
-H "Authorization: Bearer $HOSTUP_API_KEY"

Responses

200 The WHOIS record.

Response 200
{
"domain": "example.com",
"available": false,
"reason": "Domain is currently registered.",
"registrar": "Example Registrar, LLC",
"registrarUrl": null,
"registrant": null,
"nameservers": [
"ns1.example.net",
"ns2.example.net"
],
"dates": {
"registeredAt": "2017-07-16T00:00:00.000Z",
"expiresAt": "2034-07-16T00:00:00.000Z",
"updatedAt": "2026-05-13T00:00:00.000Z"
},
"statuses": [
"clientTransferProhibited"
],
"dnssec": true,
"sourceText": "Domain Name: EXAMPLE.COM\nRegistry Domain ID: 2336799_DOMAIN_COM-VRSN\nRegistrar: Example Registrar, LLC"
}
Response fields
domainstring
The domain looked up, in lowercase. Internationalized names are in punycode.
availableboolean
true when WHOIS shows no registration for the name.
reasonstring or null
Why the name is taken, such as a registration in its redemption period. null when available is true.
registrarstring or null
Registrar name, as WHOIS shows it. A domain registered through Hostup can show Hostup here.
registrarUrlstring or null
Registrar website, as WHOIS shows it.
registrantobject | null
Registrant organization and country. null when the registry hides both.
organizationstring or null
Registrant organization.
countryCodestring or null
Registrant country, as an ISO 3166-1 alpha-2 code.
nameserversarray of string
Nameservers in lowercase. Empty when WHOIS lists none.
datesobject
Dates in ISO 8601. Each is null when WHOIS does not show it.
registeredAtstring or null
When the domain was registered.
expiresAtstring or null
When the registration expires.
updatedAtstring or null
When the registry record last changed.
statusesarray of string
Status codes from the registry, such as clientTransferProhibited.
dnssecboolean or null
Whether the domain is signed with DNSSEC. null when WHOIS does not say.
sourceTextstring
The raw WHOIS text. Present only with sourceText=true when the registry returned text.

Errors

Errors are Problem Details with a stable code. Branch on the code, not on the text.

400Invalid request. The response body is an RFC 7807 Problem Details document.
401Unauthorized. Authentication is required.
403Forbidden. The caller lacks a required scope or does not own the resource.
404Not found. The resource does not exist or is not owned by the caller.
422WHOIS lookup is not available for this TLD (tld_not_supported).
429Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers.
500Internal error. Retry later or contact support if the issue persists.
502The registry’s WHOIS server did not answer (upstream_failed). Try again in a moment.