Knowledge base
Custom headers
MailerSend Enterprise plan users can add unlimited custom headers to emails. This opens up new opportunities for personalization and advanced analytics.
What are custom headers?
Custom headers are additional pieces of information added to the header section of an email. These headers allow email senders to include unique identifiers, custom tracking codes, and other metadata that can be leveraged for detailed analytics, better email management, and enhanced personalization.
How to add custom headers
Adding custom headers in MailerSend can be accomplished through the API or SMTP settings.
When sending an email via the MailerSend API, you can include custom headers by adding them to your POST request:
POST https://api.mailersend.com/v1/email
{
...
"headers": [
{
"name": "X-Custom-Header",
"value": "HeaderValue"
}
],
...
}
Limitations
Custom headers must have a name and value, with names adhering to an alphanumeric format that can include hyphens
You will not be able to override default MailerSend headers
No spaces or invalid characters are allowed in header names
- Getting started
- FAQ
-
Features
- Sending domains
- Managing API tokens
- Domain tracking options
- How to add a domain space to your account
- SMTP relay
- Webhooks
- Inbound routing
- Templates
- How to add a survey to your emails
- Email tagging
- File manager
- Email and recipient activity
- Analytics
- Split Testing
- How to use the MailerSend iOS app
- Schedule bulk emails with the bulk endpoint
- Ensuring secure SMS communication: Verification and usage limits
- SMS: How to handle opt-in and opt-out
- Custom headers
- Upcoming changes to TLS Protocol support
- How to request a dedicated IP
- Deliverability
- Account settings
- Billing
- Integrations
- How to use personalization in emails