# Audit logs

*Audit logs are available starting in* [*Enterprise Edition*](https://www.sonarsource.com/plans-and-pricing/enterprise/)*.*

Administrators can download audit logs to maintain an audit trail of the security-related changes made to their SonarQube Server instance. See the following section for the types of changes tracked in the audit logs.

## Tracked changes <a href="#tracked-changes" id="tracked-changes"></a>

Audit logs track the following changes in SonarQube Server:

* user accounts.
* permissions.
* global configuration of security-related settings.
* creating, updating, or deleting projects, applications, and portfolios.
* installing or updating plugins.
* setting or revoking licenses.

## Downloading audit logs <a href="#downloading-audit-logs" id="downloading-audit-logs"></a>

Administrators can download audit logs at **Administration** > **Audit logs**. From here, you can select the time period that you want to download audit logs for. This is limited by your housekeeping settings. See the following section for more on setting your audit log housekeeping settings.

## Audit log housekeeping <a href="#audit-log-housekeeping" id="audit-log-housekeeping"></a>

You can set how often SonarQube Server deletes audit logs in the housekeeping settings at **Administration** > **General** > **Housekeeping**. By default, SonarQube Server deletes audit logs monthly.

Setting your housekeeping policy to keep your audit logs for a long period of time (for example, only deleting logs yearly) can increase your database size and the amount of time it takes to download audit logs. To avoid this, we recommend downloading your audit logs at shorter intervals and storing them outside of SonarQube Server.

We also recommend downloading and storing your audit logs outside of SonarQube Server if you need to maintain them for a longer period of time than can be set in the housekeeping settings.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sonarsource.com/sonarqube-server/2025.1/server-update-and-maintenance/monitoring/audit-logs.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
