# isResolvable()

Source: https://findproxyforurl.net/functions/isresolvable/ · last updated 2026-10-16

`isResolvable(host)` → boolean

True if the host name resolves in DNS. The script waits for the resolver, which usually answers from a cache.

The first call for a name sends a DNS query; later calls for the same name are answered from a
cache until the stored answer expires (see [DNS in PAC files](/articles/dns-in-pac-files/)).
Used as an "am I on the internal network?" check, it still makes every request depend on DNS:
outside the company network the internal DNS server cannot be reached, and each request waits
for a timeout. Where DNS is split, the answer is simply wrong.

## Example

```js
// prefer explicit domain lists; if you must, guard it:
if (isPlainHostName(host) && isResolvable(host)) {
  return "DIRECT";
}
```


## Engine notes

- chromium: Resolves IPv4 only. (source: code, verified 2026-10-04)
- chromium: Uses the same table of names already resolved in this request as dnsResolve, and the same limit of 20 different names, so a repeat of the same name costs no lookup. (source: code, verified 2026-10-14)
- winhttp: True for a name with an IPv4 address and for a short address form such as "10.1.2"; false for a name that does not exist. (source: lab, verified 2026-10-11)
- winhttp: Keeps no table of names during one run. When the DNS server does not answer, every call waits about 12 s again. (source: lab, verified 2026-10-16)
