User Cleanup

To cleanup users and groups, you must be logged in as a user with the Jira System Administrators global permission.

Overview of global permissions in Jira

Use Instance optimizer to find and clean up Jira users that may be inactive, duplicate, unused bot, or never-used accounts. You can also find and clean up groups and directories that have no members.

User cleanup scans your instance and shows users that match one or more cleanup recommendations. From the scan results, you can review users and deactivate them in bulk.

This feature also lets Jira administrators identify directories, their groups and memberships, filter them, and export to CSV for review and cleanup.

Scan users and groups

To scan users and groups:

  1. Go to Administration > System.

  2. In the sidebar, select Instance optimizer.

  3. Open User cleanup.

  4. Click Run Scan.

The scan creates a point-in-time result set. After disabling or deleting rules, run a new scan to refresh the results.

The scan checks for rules that match these recommendations:

Recommendation

Description

Total users per instance

User counts exceeding 1M per instance

Potentially inactive users

Users that have not logged in for more than 6 months

Bot accounts

Helps identify bot accounts and their recent activities

Never logged-in users

Users that were created older than 6 months that have never logged in

Duplicate accounts

Accounts that share an email address with at least one other account.

Total users per groupGroups that have a user count of over 290,000
Groups with no usersGroups that don't have any users
Groups with potentially no active usersGroups that only have users that haven't logged in for more than 6 months

Total groups per directory

Groups exceeding 250k per directory

Directories with no users

Directories that don't have any users

Directories with potentially no active users

Directories that only have users that haven't logged in for more than 6 months


Configure limits

User cleanup uses default limits to identify users that may need review.

Limit

Default value

Inactive months

6

Created months

6

Bot groups and patterns

Empty

Groups per directory

250k

Total users

1M

Users per group

290k

To change these limits, open User cleanup, then select Configure User cleanup.

Configure bot identification

Bot identification tells User cleanup which accounts are service or automation accounts, so they surface under the Bot accounts recommendation instead of looking like ordinary inactive users. No account is treated as a bot until you add at least one rule.

To set it up, open User cleanup, select Configure User cleanup, then use the Bot identification section.

There are two kinds of rules, and an account is flagged if it matches either one:

Rule

Description

Bot groups

Accounts belonging to listed Jira groups. Search and add groups by name (max 100).

Bot username patterns

Regular expressions matched against each account’s username and display name. (max 25)

A pattern matches anywhere in the name unless you anchor it, so svc- also matches mysvc-1. Use ^svc- to match only names starting with svc-, or -bot$ for names ending in -bot.

Select Save bot identification to apply your changes. Bot rules are read when a scan starts, so run a new scan to see the effect. Results from earlier scans don’t change.

Apart from bot identification configuration, we don’t recommend adjusting default limits in production instances without consulting Atlassian support. The default limits are optimized for performance.

Review and filter results

After a scan finishes, Instance optimizer shows the matching users and the top recommendations.

You can filter results by:

  • User name

  • Status

  • Directory

  • Group
  • License

  • Optimization area
  • Last active

Directory and group filters

The Group filter becomes available after you select a directory. It initially shows up to 20 suggested groups for the selected directory. To find a group that is not in the suggestions, type in the filter and search by group name. You can select multiple groups to narrow the results.

Bulk actions - Users

You can select up to 1,000 users for cleanup at a time. Selected users can be deactivated, deleted, anonymized or reactivated.

Before deactivating, deleting or anonymizing users, we recommend exporting them to a CSV file. Deleted users can't be recovered from Instance optimizer.

To change the maximum cleanup count, set this property in your Jira home directory’s application property file, then restart Jira: jira.optimizer.plugin.user.cleanup.bulk.action.max.users. The value is capped at 5,000 per cleanup.

Bulk actions - Groups and Directories

You can select up to 1,000 Groups and Directories for cleanup at a time. Selected groups can be deleted, and selected directories can be disabled.

Before deleting groups or disabling directories, we recommend exporting them to a CSV file. Deleted groups can't be recovered from Instance optimizer. Disabled directories can be re-enabled on the User Directories page.

To change the maximum cleanup count, set this property in your Jira home directory’s application property file, then restart Jira: jira.optimizer.plugin.user.cleanup.bulk.action.max.directories  or jira.optimizer.plugin.user.cleanup.bulk.action.max.groups. The value is capped at 5,000 per cleanup.

Audit Logs

A cleanup action adds audit log entries when the cleanup starts and when it completes. It also records change of ownership of projects or components when applicable.

Scheduled scans

User cleanup includes a preconfigured scan schedule:

Task

Default schedule

Scan

Weekly on Sundays at 3:00 AM

To update the schedule, set the following property in your Jira home directory’s application property file, then restart your Jira:

  • jira.user.cleanup.scan.cron controls the scheduled scan cron.

By using a cron expression, you can specify exactly when the scan occurs. For example, the default value 0 0 3 ? * SUN schedules user cleanup scan every Sunday at 3:00 a.m.



Last modified on Sep 1, 2026

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.