# Syn Postgres Indexing

> PostgreSQL: index design and query plan optimization

- Skill: `legendtkl/syn-postgres-indexing` (Agent Skill)
- Install (CLI): `npx skillmds@latest add legendtkl/syn-postgres-indexing`
- Raw SKILL.md: https://api.skillmd.com/api/skills/legendtkl/syn-postgres-indexing/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: legendtkl (https://skillmd.com/u/legendtkl)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/legendtkl/syn-postgres-indexing

---


# PostgreSQL: index design and query plan optimization

## When to use

Use this skill for index design and query plan optimization in PostgreSQL. This skill
specifically handles index design and query plan optimization and nothing else in the
PostgreSQL family.

## Procedure

Analyze slow queries with `EXPLAIN ANALYZE`, choose between B-tree, GIN, BRIN and partial indexes, and rewrite predicates so the planner uses them. Drop redundant indexes.

## Notes

This is the PostgreSQL skill dedicated to index design and query plan optimization.
Sibling skills cover other PostgreSQL capabilities; this one
is the right choice only when the task is about index design and query plan optimization.

