scribase
Performanceversion 1.4.3

hypopg

Try an index without building it, to see if the planner would use it.

What it is for

HypoPG creates hypothetical indexes that exist only for the planner in your session. Run EXPLAIN (not EXPLAIN ANALYZE) and see whether the plan would use the index and how the cost changes, without the time, disk and locks of building it.

Enable it

sql
create extension if not exists hypopg with schema extensions;

Example

sql
select * from hypopg_create_index('create index on orders (customer_id)');

explain select * from orders where customer_id = 42;

select hypopg_reset();

Questions

How do I enable hypopg?

Run create extension if not exists hypopg with schema extensions; in the SQL editor, or switch it on from the Extensions page in the console. You do not need superuser access.

Which version of hypopg is installed?

1.4.3, on Postgres 17.6, as read from the running engine on 2026-10-08. Check yours with: select extversion from pg_extension where extname = 'hypopg';

Upstream project: github.com/HypoPG/hypopg

More performance extensions

  • pg_stat_statements Timing and call counts for every query shape (Insights reads it).
  • index_advisor Suggest the indexes that would speed up a query.
  • pg_repack Remove table and index bloat without long locks.