Glossary — in plain language

random_page_cost

Also called: random page cost, planner cost constant

In plain English

random_page_cost is the planner’s estimate of how expensive a random disk read is, relative to a sequential read fixed at 1.0. The default of 4.0 says a random read is modelled as four times costlier than a sequential one.

Why it matters

This single number heavily influences whether the planner prefers an index scan (lots of random reads) or a sequential scan. On SSDs or well-cached data, the default 4.0 is often too high; lowering it toward 1.1 makes index paths fairly costed and can fix needless sequential scans.

Was this helpful?

← Browse the full glossary