How to create a custom mail template in Jira Data Center
This page is for Jira Data Center
If you’re using Jira Server, please consult the 2024-01-23_08-51-45_Customizing email content in Jira Server.
This article is an extension of Customizing email content for Jira Data Center administration page. If this is your first reading about email content customization or email templates, please go to that page initially.
Customizations to Velocity templates or other Jira files are not included in the scope of Atlassian Support.
Summary
To create a new email template in Jira Data Center, to be used along with specific Jira event, there are steps to be followed, listed below.
Attention! This article applies to version 8.14 or later. Previous versions of Jira use a diferent format to download/upload templates, the applied changes can be read on Jira 8.14 release notes (Email templates made better).
Steps
- Download the email templates from Administration > System > Email templates
- Using the structure from the downloaded Zip file, create new
template.vm
files in thehtml
,text
, andsubject
directories, based on the existing files in those directories - Zip the templates folder and upload the zipped email templates on Administration > System > Email templates (note it will overwrite the information in <Jira-shared-home>/data/templates/email).
- Edit the <Jira app folder>/
atlassian-jira/WEB-INF/classes/email-template-id-mappings.xml adding the created templates to
make them valid choices for when you are adding a new event. - Restart Jira
Example
- Download the email templates from Administration > System > Email templates
- Using the structure from the downloaded Zip file, create new template
.vm
files in thehtml
,text
, andsubject
directories, based on the existing files in those directories - Zip the templates folder and upload the zipped email templates on Administration > System > Email templates (note it will overwrite the information in <Jira-shared-home>/data/templates/email).
- Edit the <Jira app folder>/
atlassian-jira/WEB-INF/classes/email-template-id-mappings.xml adding the created templates to
make them valid choices for when you are adding a new event. - Restart Jira
- Validation