Score
8.5
/ 10
Installs
262K
Repo Stars
2.3K
Last Updated
0d ago
Quality Ratio
100%
Description
Verified
Language
TypeScript
First Published
Jan 2026
Summary
The Supabase Postgres Best Practices agent skill provides a comprehensive, prioritized guide for optimizing Postgres database performance, security, and schema design. This agent skill is designed for developers, database administrators, and architects seeking to build and maintain high-performance, secure Postgres databases, especially within Supabase environments. It is a well-adopted skill with solid traction in the registry. It contains expert-curated rules across eight categories, prioritizing critical areas like query performance, connection management, and Row-Level Security. This enables the AI agent to analyze database operations, offering practical advice and examples of correct and incorrect SQL to identify and resolve common performance and security anti-patterns during query writing or schema reviews.
Skill Definition
Comprehensive performance optimization guide for Postgres, maintained by Supabase. Contains rules across 8 categories, prioritized by impact to guide automated query optimization and schema design.
When to Apply
Reference these guidelines when:
- Writing SQL queries or designing schemas
- Implementing indexes or query optimization
- Reviewing database performance issues
- Configuring connection pooling or scaling
- Optimizing for Postgres-specific features
- Working with Row-Level Security (RLS)
Rule Categories by Priority
| Priority | Category | Impact | Prefix |
|---|---|---|---|
| 1 | Query Performance | CRITICAL | query- |
| 2 | Connection Management | CRITICAL | conn- |
| 3 | Security & RLS | CRITICAL | security- |
| 4 | Schema Design | HIGH | schema- |
| 5 | Concurrency & Locking | MEDIUM-HIGH | lock- |
| 6 | Data Access Patterns | MEDIUM | data- |
| 7 | Monitoring & Diagnostics | LOW-MEDIUM | monitor- |
| 8 | Advanced Features | LOW | advanced- |
How to Use
Read individual rule files for detailed explanations and SQL examples:
references/query-missing-indexes.md
references/query-partial-indexes.md
references/_sections.md
Each rule file contains:
- Brief explanation of why it matters
- Incorrect SQL example with explanation
- Correct SQL example with explanation
- Optional EXPLAIN output or metrics
- Additional context and references
- Supabase-specific notes (when applicable)