Copy values between two custom fields with Jira Data Center automation rules
Platform Notice: Data Center Only - This article only applies to Atlassian apps on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
If you're trying to copy the content of 1 text field (Field A) into another text field (Field B), you can accomplish this using a Jira automation rule. The same methods can also be used with most other field types, including number fields, and user picker fields.
Environment
Jira Data Center 8.0.0 and any higher version
Automation for Jira 7.4.0 and any higher version
Solution
Pick the right method for your situation
Same field type, no transformation needed → Use the "Edit issue" action → "Copy from" dropdown. This is the simplest and recommended approach.
Same field type, with concatenation or formatting → Use the "Edit issue" action with a smart value such as
{{triggerIssue.fieldName}}.Different field types (e.g. text → user picker) → Add a Lookup Issues step first to resolve the value; document the type mismatch in the rule description.
Cascading fields, custom date formats, or list field types → Refer to the Jira automation smart values reference for the correct syntax for your field type before configuring.
Use the Copy From action in automation
Navigate to either your desired project, or the Global automation page in Jira
Create a new automation rule
Add the Edit Issue action to the rule
Select the Field that needs to be set ("Field B" in our example)
Select ...(More options) > Copy from...
Issue to copy value from: "Current Issue"
Field to copy value from: select the source field ("Field A" in our example)
If the field isn't directly available, use Smart Values
Some fields, like the Original Story Points field, aren't directly supported by Automation, and won't appear in the Copy from dialog in the rule editor.
We can still copy data from these fields, but we'll leverage Smart Values to do so. Let's build a rule to copy Original Story Points into the Story Points field:
Navigate to either your desired project, or the Global automation page in Jira
Create a new automation rule
Add the Edit Issue action to the automation rule
Select the Field that needs to be set ("Story Points" for example)
Copy and paste the string below into the field
|
Keep in mind, you can also change the Original Story Points field in the Smart Value to other fields that aren't directly available in the Automation editor.
Use JSON object in Automation rules
If you wish to use a JSON formula to perform the field copy via the Additional fields section, you can follow these steps.
Add the Edit Issue action
Do not select any fields
Instead, expand the More Options setting
Copy the JSON formula below into the Additional fields section
Make sure to change "Target Field" with the name of the target field of your choice, and "Source Field" with the name of the source field of your choice.
|
Note: Inserting JSON objects will only work with basic field types such as the Text and Number types. If you are looking into using a JSON formula to copy array-type fields such as Multi-User picker or Multi-Option fields, you will need to use a different syntax.
The solutions that apply to these types of fields are described in the articles below:
Why didn't the value copy? Common causes
If the rule runs without errors but the destination field remains empty, check the following:
Field type mismatch — Copying a text value into a number field (or vice versa) will silently fail with no error. Ensure both fields are the same type, or use a lookup/transformation step to convert the value first.
Field not on any screen — Automation cannot set a field that isn't on any screen for the affected issue type. Verify the destination field is on the relevant Create/Edit/View screen in Project Settings → Screens.
Workflow validator or required field blocking the edit — A workflow validator or a required field on the edit screen can silently block the Edit Issue action. Check Project Settings → Workflows for validators on the current transition.
Rule actor missing "Edit Issues" permission — The user or app account running the rule must have the Edit Issues project permission. Go to Project Settings → Permissions and verify the rule actor is included. See Run Jira automation rules as another user for rule actor configuration.
Source field empty at trigger time — If using "Copy from", verify the source field has a value when the trigger fires. Fields set by post-functions or populated asynchronously may be empty at trigger time. Consider adding a condition to check the source field is not empty before the Edit Issue action.
Related articles
Jira automation triggers — full list of available triggers for automation rules
Jira smart values — issues — reference for all available smart values, including field-type-specific syntax
Run Jira automation rules as another user — configure the rule actor and its permissions
Edit issue fields with Jira automation — full reference for the Edit Issue action
Get started with Jira automation — automation overview and setup
Was this helpful?