JIRA Automated old issue deletion


Is there a way in JIRA to administer a records retention policy? For example, all issues that are closed and are older than 6 month should be automatically deleted from the system.

2 answers

1 accepted

2 votes
Accepted answer


An easier way to do this would be to use the JIRA Automation Plugin. You can create the filter as Tiago mentioned, and the Automation tool will run it and delete the issues when you want. :)


OK thanks! I am going to dive into Jelly developement. I am not sure how XML will be a powerful enough language to be able to do the kind of analysis I need, but I will try. In my head I would need to run a JQL filter to find whatever issues that we dinfe as "old", store that list somehow and then run some further filters on them to ensure that we would want to delete them, then after that run a delete on a subset of the original "old" list, and send a report to myself to let me know of what issues were deleted so that if a user complains that their issue has dissappeared I have a record.

It still surprises me that there isn't a default setting to remove old issues built-in, as I would assume most companies would not want to hold on to old issues forever for space/legal/other reasons.


I'm not sure if I quite understood your comment. With the Automation Plugin you should simply need to create the JQL query (something like "Created <= startofMonth(-6) AND resolution IS NOT EMPTY " for issues older than 6 months), and the automation would take care of the rest.

There shouldn't be any need to create custom scripts or develop anything.

Oh wow, I will look into that for sure. Of course I am hoping that there are no more requirements than closed date + 6 months, but I hope I can cover it all with JQL Queries. Thanks!

Let us know if we can help! :)

We are also big fans of the JIRA Automation Plugin. To make your process safer, you may want to archive the issues to be deleted into a PDF document (with comments, attachments, etc.) using https://marketplace.atlassian.com/plugins/com.midori.jira.plugin.pdfautomation It integrates nicely with the Automation Plugin, so you can chain actions like "run the JQL, then save the resulted issues to a PDF document and finally delete those issues".

Hi Robert, I think you can use a Jelly script to do this. We don't have a Jelly tag to delete issues, but here in this other question you can see an example of code to delete an issue. You may to tweak a little the code to fit your requirements.

I hope it helps.


OK cool, I am the new Atlassian administrator and have gotten up to speed a bit on Confluence, Stash, and Bamboo, I am still learning JIRA though, looking forward to learning Jelly. I see this link https://confluence.atlassian.com/display/JIRA/Jelly+Tags#JellyTags-EnablingJelly, is this the best place to start? Also I will return to select answer if this works (I have to reboot JIRA to turn Jelly on and that is an after hours operation)

Hey, now that I have jelly enabled I am a little confiused on how I go and find say:

All closed issues that are over 1 year old.

That is my first and foremote need from there I would like an automatted deletion process by is Jelly or SQL.


Hi Robert, you may use a saved JQL filter to this. In this doc you'll see an example of Jelly script to trigger trasition for specific issues based on a filter (in this case, filter id 11505). We may do something similar to find the issues and delete then afterwards.


Suggest an answer

Log in or Sign up to answer
Community showcase
Published Jan 08, 2019 in Jira

How to Jira for designers

I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...

919 views 3 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you