Summary
The pg_statio_all_indexes view will contain one row for each index in the current database, showing statistics about I/O on that specific index. The pg_statio_user_indexes and pg_statio_sys_indexes views contain the same information, but filtered to only show user and system indexes respectively.
(Description quoted from the official PostgreSQL documentation.)
Columns
The pg_statio_all_indexes statistics view exposes the following columns (names, types and descriptions are taken verbatim from the PostgreSQL documentation):
relidoid
OID of the table for this indexindexrelidoid
OID of this indexschemanamename
Name of the schema this index is inrelnamename
Name of the table for this indexindexrelnamename
Name of this indexidx_blks_readbigint
Number of disk blocks read from this indexidx_blks_hitbigint
Number of buffer hits in this indexstats_resettimestamp with time zone
Time at which these statistics were last reset
Version applicability
Present in PostgreSQL 17, 18, 19 (verified against each release’s documentation). This is a long-standing system object that also exists in earlier PostgreSQL releases.
Related & references
Reference: PostgreSQL documentation — pg_statio_all_indexes.