MX Lookup

Look up MX (Mail Exchange) records for any domain. Returns all mail server hostnames and their priorities, sorted from highest to lowest priority (ascending numeric value). Use this to verify email deliverability, discover mail server infrastructure, and diagnose email routing issues.

Get API Key

Overview

Use Cases

  • Verifying a domain is configured to receive email before sending
  • Email deliverability checks in validation pipelines
  • Discovering mail server infrastructure for a domain
  • Diagnosing email routing and delivery issues
  • Building email validation tools that go beyond syntax checking

Features

Returns all MX records for any domain
Records sorted by priority (lowest numeric value = highest priority)
Includes both hostname and priority for each mail server
Returns 404 when no MX records exist for the domain

API Endpoints

MX Lookup

Retrieve all MX records for a domain. Results are sorted by priority ascending (lowest numeric value has highest mail delivery priority per RFC 5321).

GET
https://api.requiems.xyz/v1/tech/mx/{domain}

Parameters

Name Type Required Description
domain string Required The domain name to look up MX records for (e.g. gmail.com)

Try it out

Live Demo
Request

The domain name to look up MX records for (e.g. gmail.com)

Response Fields

Field Type Description
domain string The domain that was queried
records array List of MX records, sorted by priority ascending (lowest number = highest priority)
records[].host string Fully-qualified hostname of the mail server (typically ends with a trailing dot)
records[].priority integer MX priority value. Lower values have higher delivery priority per RFC 5321.

Code Examples

curl "https://api.requiems.xyz/v1/tech/mx/gmail.com" \
  -H "requiems-api-key: YOUR_API_KEY"

Error Responses

bad_request

The domain parameter is not a valid domain name.

not_found

No MX records were found for the domain (domain may not accept email).

internal_error

DNS lookup failed due to an unexpected server error.

Frequently Asked Questions