Ranks normalized query pressure by calls, total time, mean time, rows, temp writes, and reset caveats.
Strongest query history signalHow optimization works
Database Optimization Tool turns PostgreSQL evidence into reviewable recommendations by separating collection, classification, recommendation, and validation. The workflow is built for teams that want useful database direction without handing over production control.
- Default boundary
- read-only collector, manual upload, no production writes
- Best evidence
- EXPLAIN, pg_stat_statements, table/index stats, and benchmark artifacts
The report says where its confidence comes from.
Strong evidence narrows the recommendation. Missing evidence stays visible as a coverage note instead of being hidden behind a confident-sounding answer.
Shows scans, joins, sorts, buffers, filters, row estimates, and whether a candidate fix changes the actual plan.
Plan-backed review pathConnects relation size, seq scans, index scans, dead rows, last analyze, and unused-index cost.
Works with restricted rolesMarks unavailable extensions, blocked views, absent EXPLAIN, stale stats, or managed Postgres visibility limits.
Coverage note, not guessworkSafety is part of the product surface.
The local collector is designed around restricted PostgreSQL users and no production writes.
Generated files stay local until your team reviews them and chooses to attach them to a project.
The website does not create indexes, run VACUUM, change settings, or execute production rollout steps.
Any command path that can execute SQL requires a clear local consent flag and a staging or sandbox mindset.
Optimization starts from the user-visible slowdown.
Slow dashboard
- Signal
- Repeated scans, sort pressure, temp writes, and offset pagination.
- Next step
- Candidate index or rewrite, plus EXPLAIN checks before a rollout.
Write-heavy table
- Signal
- Unused indexes, hot relations, dead-row pressure, and rising maintenance cost.
- Next step
- Review whether reads justify write overhead before dropping or adding indexes.
Managed Postgres
- Signal
- RDS, Cloud SQL, Supabase, or Neon may hide privileged settings and host metrics.
- Next step
- Keep useful low-privilege evidence while marking the gaps clearly.
Staging validation
- Signal
- Before/after SQL, fixture plan, EXPLAIN samples, and benchmark artifact.
- Next step
- Compare the change outside production and package a handoff for the owner.
A rough idea should not look like a validated production result.
Open the local evidence layer, keep the SaaS product private.
The public GitHub repository makes `postgresaudit` reviewable: CLI commands, synthetic examples, schemas, permission guidance, redaction notes, and smoke tests. It does not publish the production SaaS app.
