GET /mx/{domain}

MX lookup API

See where a domain routes its mail.

Try it

mx

MX list, priority and host (empty if none)

1

Pass a domain

Hosts come back sorted the way mailers try them.

2

Empty means none

No mail exchanger is an empty list, not an error.

3

Fresh on lookup

A day-old copy serves while DNS re-checks.

10 million indexed.

Mail hosts and priority. Every plan.

10M+
domains indexed
24h
refresh on lookup

Pass a domain. Hosts come back sorted the way mailers try them, lowest number first. Empty mx means no mail exchanger. That is an answer, not an error.

Lookups refresh when you ask. A day-old copy serves immediately while we re-check DNS. Names we have not seen resolve live and join the index. Availability lives on /domain/{domain}. This call is mail routing only, on every plan.

RESPONSE

$ curl "https://api.parseapi.com/mx/gmail.com" \
  -H "X-API-Key: YOUR_API_KEY"

// 200 · ~35ms US · ~97ms worldwide
{
  "domain": "gmail.com",
  "mx": [
    {
      "priority": 5,
      "host": "gmail-smtp-in.l.google.com"
    },
    {
      "priority": 10,
      "host": "alt1.gmail-smtp-in.l.google.com"
    },
    // ... 3 more
  ]
}

Response fields

domain
Hostname checked
mx
MX list, priority and host (empty if none)

QUESTIONS

What comes back?
Hosts and priority, sorted the way mailers try them. Empty mx means the domain has no mail exchanger.
How fresh is it?
Lookups refresh on use. A day-old copy serves immediately while we re-check DNS. New names resolve live.
Does empty MX mean the domain is free?
No. Empty mx is mail routing only. Availability is GET /domain/{domain}.

SPEED

How long /mx takes.

US

16ms

EU

31ms

APAC

46ms

LatAm

16ms

ME

115ms

See live status →

Coverage

Live DNS. Hosts refresh when you look them up.

See the mail servers on any domain with the MX lookup.