Email and campaigns

Business email

Business email on your own domain — adding the domain, its DNS records, mailboxes, aliases, webmail, setting it up in Outlook and on phones, and sending mail by API.

Meghly runs business email on your own domain (such as info@shop.com.bd). It takes three steps: add the domain, put its DNS records in place, and create mailboxes.

1. Adding the domain

On the panel's Domains page, click Add domain and fill in:

FieldWhat it is
Domain nameThe domain mail runs on, such as shop.com.bd
Catch-all addressThe mailbox that gets mail sent to addresses that do not exist (optional; can only be set when the domain is added)
Tracking domainA sub-domain for tracking campaign opens and clicks, such as track.shop.com.bd (optional)
Bounce domainThe sub-domain bounces come back to; bounce.<domain> when left empty
Receiving enabled / Sending enabledWhether the domain receives and sends mail (both on by default)

As soon as the domain is added, Meghly creates a DKIM key for it (RSA 2048). The domain starts as Pending and turns Verified once all its DNS records are in place.

2. Putting the DNS records in place

Open the domain: its DNS records tab lists every record it needs, with the state of each:

RecordWhereWhat it does
MXon the domain (@)Tells other servers where your mail is delivered
SPF (TXT)on the domain (@)Declares which servers may send mail for your domain
DKIM (TXT)<selector>._domainkeyThe public key that checks the signature on every message
DMARC (TXT)_dmarcThe policy receivers follow when SPF or DKIM fails
CNAMEthe tracking sub-domainOnly when a tracking domain is set

Each record shows In place, Different value (with the value it has now) or Not added yet. Copy the right value from Value to add into your DNS provider, then click Check again. Meghly also checks the records by itself every hour.

There are three easy ways to put the records in place:

  • The domain's DNS is on Meghly: nothing to do — the mail records are added by themselves. See DNS hosting.
  • Cloudflare: give Publish to Cloudflare a Cloudflare API token (with "Zone → DNS → Edit" and "Zone → Zone → Read"). Meghly adds all the records at once; the token is never stored. A record that already exists with a different value is reported before anything is changed.
  • Any other provider: Export zone file downloads every record in one file, or copy them one by one.

DMARC starts at p=none, so no legitimate mail is blocked. After a few weeks of everything working, move the policy step by step to quarantine and then reject.

Rotating the DKIM key

Changing the DKIM key now and then is good practice. On the domain's DKIM keys tab, Rotate key makes a new key (2048, 3072 or 4096 bit). Add the new key's DNS record; the old key stays valid until its DNS record is removed, so no mail is caught out during the change.

3. Creating mailboxes

On the domain's Mailboxes tab, click Add mailbox and fill in:

  • Address — such as info or sales.
  • Display name — the name recipients see (optional).
  • Password — at least 12 characters, with at least one upper-case letter, one lower-case letter and one digit.
  • Quota (GB) — the mailbox's space, 2 GB by default.

Each mailbox's menu has Open webmail, Mail client setup, Autoresponder (out of office), Reset password and Delete mailbox.

Autoresponder (out of office)

Going on leave? Turn on Autoresponder (out of office) to reply automatically. You can set start and end dates (optional) and how many days pass before the same sender is answered again (1–30). Mailing lists, automatic mail and spam are never answered.

Aliases and forwarding

To send one address's mail on to one or more others, use Add alias on the domain's Aliases tab. Put the original address in Source and where it goes in Destination (several separated by commas). To keep a copy in the original mailbox too, tick Keep a copy in the source mailbox.

4. Webmail and mail apps

To read mail in the browser, use the Webmail button. The mailbox also works in Outlook, Thunderbird and the mail apps on Android and iPhone. Always use the full email address as the user name:

ForProtocolPortSecurity
ReceivingIMAP993SSL/TLS
ReceivingPOP3995SSL/TLS
SendingSMTP587STARTTLS
SendingSMTP465SSL/TLS

The server name (host) is shown in the mailbox's Mail client setup, along with step-by-step guides for Outlook, Thunderbird, Android and iPhone; Email these settings to sends them to someone (the password is never sent). Thunderbird often finds the settings by itself.

If you use one mailbox on several devices, choose IMAP rather than POP3, so every device shows the same mail and folders.

Sending limits

  • How many messages may be sent each hour and each day depends on your plan. The limit is for the whole account and counts every recipient.
  • A message, attachments included, is at most 25 MB.
  • Every message is checked for spam before it goes out.
  • If more than 10% of at least 100 messages in an hour bounce, the account's sending pauses for 30 minutes by itself, to protect your domain's reputation.

Following your mail (Messages)

The Messages page shows every message sent and received by your account and its state — Delivered, Deferred (held up for now, it will be tried again), Bounced, Failed and so on. Click a message to see the receiving server's answer (DSN code), the last error and every step it went through. Send test sends a test message. The record of each message is kept for 90 days.

Sending mail from your app by API

To send welcome mail, receipts or password resets from your website or app, use the API. First create a key with the SendMail scope on the API keys page (see Account and team), then:

curl
curl https://api.example.com/api/v1/messages \
  -H "X-Api-Key: mpk_..." \
  -H "Content-Type: application/json" \
  -d '{
    "from": "info@shop.com.bd",
    "fromName": "Shop",
    "to": "customer@example.com",
    "subject": "Your order is confirmed",
    "html": "<p>Thank you! Your order number is <b>1042</b>.</p>"
  }'

Put Meghly's API address in place of api.example.com. On success the API answers 202 and the message is queued; its state shows on the Messages page.

  • Templates: instead of html, give templateSlug and variables to build the message from a template on the Templates page. Templates may use variables such as {{ firstName }}; the Templates page edits, previews and saves them.
  • Other fields: cc, bcc, replyTo, tags, attachments, and sendAt to send at a set time.
  • Never the same message twice: send an Idempotency-Key header; a repeated request with the same key sends nothing new.
HTTP codeWhy
429The hourly or daily limit is used up, or sending is paused because of bounces
422The recipient is on the suppression list (an earlier bounce or complaint)
413The message is larger than 25 MB

When something goes wrong

What you seeCause and fix
The domain stays PendingSee which records the DNS records tab shows as Not added yet or Different value; DNS changes can take a little while.
My mail lands in spamMake sure SPF, DKIM and DMARC are all In place; if the domain has an older SPF record, remove it so only one remains.
A mail app cannot sign inUse the full email address as the user name, and check the ports and security against the table above.
The domain cannot be deletedDelete all its mailboxes first.
The API answers 429The plan's hourly or daily limit is used up; try again later or move to a bigger plan.

Stuck?

Talk to our engineers directly — by phone or email.

01782618248shohag.meghly@gmail.com