Quickstart
Receive your first inbound email
Add the inbound MX record, send a test message to your inbound subdomain, find it in the dashboard, and process it with an email.received webhook and the API.
This quickstart sets up a domain to receive email, so your app can handle replies, support requests or forwarded messages. You’ll add one DNS record, send a test message, and then receive it with a webhook and fetch its full content from the API.
Before you begin
- A verified sending domain, such as
acme.com. Inbound email only works on domains that are verified in your workspace. See Add a domain. - Credits in the workspace. Each received email costs 1 credit.
How inbound addresses work
Emailit receives mail on a subdomain of your sending domain, by default inbound. Any address on that subdomain works, so support@inbound.acme.com and reply-4821@inbound.acme.com both arrive in the same workspace. Your main domain’s MX records, for example for Google Workspace or Microsoft 365, stay as they are.
Add the inbound MX record
-
Open the domain. Go to Email APIDomains and open
acme.com. The MX record forinbound.acme.comis listed with the other DNS records. It’s optional, so the domain stays verified without it. -
Add the record at your DNS provider.
Type Name Value Priority MX inbound.acme.cominbound.emailitmail.com10 Some DNS providers want only
inboundin the name field. Others want the full name. -
Check DNS. Select Check DNS on the domain page and wait until the inbound record shows OK. DNS changes usually take a few minutes, but can take up to 48 hours.
To receive on a different subdomain, such as replies.acme.com, set inbound_key to replies when you create or update the domain with the API, then publish the MX record for that name instead. The dashboard shows the inbound subdomain but doesn’t let you change it.
Send a test email
From your personal mailbox, send an email to any address on the inbound subdomain, for example hello@inbound.acme.com.
Go to Email APIEmails and open the Incoming tab. The message appears with the status received. Open it to see the sender, the headers, the content and any attachments.
If it doesn’t arrive, check that the MX record shows OK and that the domain is verified. If the workspace has no credits left, Emailit refuses the message with a temporary error, and the sender’s server tries again later.
Get notified with a webhook
To process inbound email in your app, subscribe to the email.received event.
-
Create the webhook. Go to Email APIWebhooks, select Add webhook, and enter a name and your HTTPS endpoint, for example
https://acme.com/webhooks/emailit. Copy the webhook secret. You need it to verify signatures. -
Choose the event. A new webhook receives every event. Open the webhook’s Settings tab and select only
email.received, or keep all events and filter in your code. -
Send another test email to
hello@inbound.acme.com.
Emailit sends a signed POST to your endpoint. The body is a JSON array, because one request can carry up to 100 events:
[
{
"event_id": "evt_2pXb7Lw9QmKc4RtN8yVd3Hs",
"type": "email.received",
"data": {
"object": {
"id": "em_2pXb7Kq4NvL8mWc3RtB9yZd",
"object": "email",
"from": "ada@example.com",
"to": "hello@inbound.acme.com",
"subject": "Question about my order",
"created_at": "2026-10-01T09:30:12.418Z"
}
}
}
]The event has the sender, the recipient and the subject, but not the body. Verify the X-Emailit-Signature header before you trust the request. See Request signature.
Fetch the full email
Use the id from the event to fetch the message with a Full Access API key:
curl https://api.emailit.com/v2/emails/em_2pXb7Kq4NvL8mWc3RtB9yZd \
-H "Authorization: Bearer $EMAILIT_API_KEY"The response includes the parsed headers, the text and HTML body, and the attachments:
{
"object": "email",
"id": "em_2pXb7Kq4NvL8mWc3RtB9yZd",
"type": "inbound",
"from": "ada@example.com",
"to": "hello@inbound.acme.com",
"subject": "Question about my order",
"status": "received",
"headers": { "...": "..." },
"body": {
"text": "Hi, where is my order #1042?",
"html": "<p>Hi, where is my order #1042?</p>"
},
"attachments": []
}To get the original message instead, call GET /emails/{id}/raw. Message content is kept for your plan’s retention period, so fetch it soon after the event arrives. See Data retention.
Pricing
Each received email costs 1 credit, the same as sending one. See Credits.