Specifies the minimum number of inserted, updated or deleted tuples needed to trigger an ANALYZE in any one table.
At a glance
| Property | Value |
|---|---|
| Parameter | autovacuum_analyze_threshold |
| Category | Vacuuming |
| Default | 50 |
| Value type | integer |
| Change scope | Reload (postgresql.conf, SIGHUP) |
| Available in | PostgreSQL 12, 13, 14, 15, 16, 17, 18, 19 (added in 12) |
What it does
Specifies the minimum number of inserted, updated or deleted tuples needed to trigger an ANALYZE in any one table. The default is 50 tuples. This parameter can only be set in the postgresql.conf file or on the server command line; but the setting can be overridden for individual tables by changing table storage parameters.
(Description quoted from the official PostgreSQL documentation.)
How to apply a change
Set it in postgresql.conf (or with ALTER SYSTEM) and reload with SELECT pg_reload_conf(); or pg_ctl reload — no restart needed.
Inspect the current value and source with SHOW autovacuum_analyze_threshold; or SELECT name, setting, unit, context, source FROM pg_settings WHERE name = 'autovacuum_analyze_threshold';.
Tuning guidance
Lower it (or the scale factor) on large tables so statistics refresh after fewer changes, keeping the planner accurate; raise it to cut ANALYZE frequency on churn-heavy small tables.