From 18c26bf933050d8ab97d367ff166c0ac826efc01 Mon Sep 17 00:00:00 2001 From: Gabriel Claudino Date: Fri, 7 Aug 2026 17:58:30 +0100 Subject: [PATCH] docs(auth): clarify audit logs storage options and configuration (#48852) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary - Clarify that external log storage is the default - Explain that Postgres database storage is optional - Fix grammar and typos - Improve admonition messaging to be more actionable - Simplify toggle step wording for clarity Slack thread with team-auth: https://supabase.slack.com/archives/C022071RB2L/p1785945149999009 ## Summary by CodeRabbit * **Documentation** * Clarified that audit logs are stored in external log storage by default. * Documented optional database storage in `auth.audit_log_entries`. * Added instructions for enabling or disabling database storage with the “Write audit logs to the database” toggle. * Noted that enabling database storage incurs additional database storage costs. --- apps/docs/content/guides/auth/audit-logs.mdx | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/apps/docs/content/guides/auth/audit-logs.mdx b/apps/docs/content/guides/auth/audit-logs.mdx index 773050533fe..9d74ea36edb 100644 --- a/apps/docs/content/guides/auth/audit-logs.mdx +++ b/apps/docs/content/guides/auth/audit-logs.mdx @@ -18,25 +18,19 @@ Supabase auth audit logs automatically capture all authentication events includi ## Storage options -By default, audit logs are stored in two places: +Audit logs are stored in: -1. **Your project's Postgres database** - Stored in the `auth.audit_log_entries` table, searchable via SQL but uses database storage -2. **External log storage** - Cost-efficient storage accessible through the dashboard +- **External log storage** - Cost-efficient storage accessible through the dashboard +- **Postgres database** (optional) - Stored in the `auth.audit_log_entries` table, searchable via SQL, but uses additional database storage -You can disable Postgres storage to reduce database storage costs while keeping the external log storage. +You can enable or disable Postgres database storage to optimize your costs. ### Configuring audit log storage 1. Navigate to your project’s dashboard 2. Go to **Authentication** -3. Find the **Audit Logs** under **Configuration** section -4. Toggle on "Disable writing auth audit logs to project database" to disable database storage - - - -Disabling Postgres storage reduces your database storage costs. Audit logs will still be available through the dashboard. - - +3. Find the **Audit Logs** under the **Configuration** section +4. Toggle "Write audit logs to the database" on to enable or off to disable database storage ## Log format