How to add custom headers to emails?

Is it possible to add custom message headers to email sent by Auth0 using our configured SMTP provider?

I’m not seeing anything in the SMTP provider configuration, or in the email templates section either…



I’m afraid the answer is no. However I’m interested to know which headers you require and what problem you are trying to solve. Maybe there is another alternative?

Our email provider support “marketing” and “transactional” emails from being sent, and allow our users to opt-out of marketing email while still getting the transactional ones. By default emails are considered to be marketing and we need to include a custom header to mark it as transactional.

Without that, users don’t get any email coming from auth0… Workaround is to implement anything that uses email ourself (email verification, password reset, etc.), but this reduce the value we get from Auth0, so not good for you :wink:

+1 to the case
We do use email performance tracking & reputation monitoring to measure email bounce, open & click rate. Having the possibility to add a custom header would allow us to break down email feedback data.

Apologies for resurrecting this thread. We want to let SparkPost to use dedicated IP Pools (high reputation) to send Auth0 related emails.

E.g. ```
X-MSYS-API: { “options”: { “ip_pool”: “my_new_ip_pool” } }
1 Like

Hi, we want this for Sendgrid integration as well.

The Sendgrid API allows us to define suppression groups when sending emails but Auth0 does not expose this option, so our transactional emails go to the same list as our promotional ones (and users often unsub to promotional emails, then get locked out of their accounts because they also unknowingly unsubbed to forgot password and 2fa emails).

The headers/API Options are described here:

Any interest in surfacing this feature? Having Auth0 send our transactional emails through Sendgrid email Relay is great, but useless unless we can mark emails as transactional.

Definitely reduces the Auth0+Sendgrid value as we are now looking at sending the transactional emails ourselves.

Edit: Adding this to the SMTP custom integration would work for us too, we could switch from regular Sendgrid API to using the Sendgrip SMTP API.



It seems we’re running into the same issues here. We’re using Mandrill as SMTP provider and I was looking into how to add the List-Unsubscribe header.

Your comment was very informative @charles3! We’re still getting notified by some of our end users still needing to check their junk folder for their Change password mails.

FYI: the Mail Tester site is very helpful for checking the quality of your e-mails.


Just to say that we’d also like this feature.
We’re using AWS SES via the SMTP provider where we’re sending an email using an IAM user from one AWS account but using the email identity in another AWS account (this is common practice I believe to only have one account which has all the email setup). In order to do this, Amazon require you to set various headers to specify which resource to send the email as e.g. X-SES-SOURCE-ARN, X-SES-FROM-ARN etc. (Sending emails for the identity owner for Amazon SES sending authorization - Amazon Simple Email Service)
There is also no way I have seen in the Auth0 SES provider to specify the sending ARN so we cannot do it that way.



In case it helps anyone else, there is a feature of the Management API where you can set headers on emails except that the only header you can set (that I can see) is “X-SES-Configuration-Set” which does not solve my specific problem.!/Emails/patch_provider