supabase-postgres-best-practices

Audit Supabase Postgres databases for query, schema, and RLS performance issues.

2|Updated Apr 14, 2026
One-click install
npx skills add https://github.com/emilyLi2020/WAVE --skill supabase-postgres-best-practices-emilyli2020
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: supabase-postgres-best-practices
Source: https://github.com/emilyLi2020/WAVE/tree/main/.agents/skills/supabase-postgres-best-practices
Command: npx skills add https://github.com/emilyLi2020/WAVE --skill supabase-postgres-best-practices-emilyli2020

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill eliminates slow database performance, inefficient schema designs, connection exhaustion, and misconfigured Row Level Security policies that cause application downtime and poor user experience for Supabase and Postgres users.

Core Features & Use Cases

  • 8 Prioritized Rule Categories: Covers critical (query performance, connection management, security/RLS) to incremental (monitoring, advanced features) optimization areas, each with clear impact ratings.
  • Actionable SQL Examples: Every rule includes incorrect and correct SQL snippets, EXPLAIN output guidance, and Supabase-specific notes to ensure correct implementation.
  • Use Case: A backend developer troubleshooting slow user dashboard queries can use this Skill to identify missing indexes, rewrite inefficient JOINs, and configure connection pooling to reduce query latency by 10x or more.

Quick Start

Use this skill to audit your Supabase Postgres database for performance bottlenecks and apply the highest-impact optimizations first.

Frequently Asked Questions about supabase-postgres-best-practices

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I optimize slow Supabase Postgres queries?

To optimize slow Supabase Postgres queries, apply prioritized rules for query rewriting, missing index creation, and inefficient JOIN elimination to reduce dashboard latency by 10x or more using provided SQL examples.

What is the best way to configure connection pooling in Supabase?

Configuring connection pooling in Supabase requires applying specific rules to prevent connection exhaustion and application downtime, ensuring reliable scalability by managing active database connections efficiently.

How do I fix misconfigured Row Level Security policies in Postgres?

Fixing misconfigured Row Level Security policies in Postgres involves tuning RLS rules to prevent performance degradation while maintaining security, guided by incorrect and correct SQL examples.

Does this database performance optimization guidance work for standard Postgres or only Supabase?

This database performance optimization guidance applies to both Supabase and standard Postgres environments, providing actionable rules for schema design review, index creation, and query optimization with Supabase-specific notes.

Why does my Supabase database experience connection exhaustion during peak usage?

Supabase database connection exhaustion during peak usage typically stems from misconfigured connection pooling or inefficient schema designs, requiring immediate connection management and query optimization to restore application reliability.