diff --git a/doc/src/sgml/pageinspect.sgml b/doc/src/sgml/pageinspect.sgml
index d4ee34ee0f..4e29b7e00c 100644
--- a/doc/src/sgml/pageinspect.sgml
+++ b/doc/src/sgml/pageinspect.sgml
@@ -153,6 +153,92 @@ test=# SELECT fsm_page_contents(get_raw_page('pg_class', 'fsm', 0));
      </para>
     </listitem>
    </varlistentry>
+
+   <varlistentry>
+    <term>
+     <function>get_compress_address_header(relname text, segno integer) returns record</function>
+     <indexterm>
+      <primary>get_compress_address_header</primary>
+     </indexterm>
+    </term>
+
+    <listitem>
+     <para>
+      <function>get_compress_address_header</function> returns global
+      information about the compressed address file for a compressed
+      relation. For example:
+<screen>
+test=# select * from get_compress_address_header('tb1',0);
+ nblocks | allocated_chunks | chunk_size | algorithm | last_synced_nblocks | last_synced_allocated_chunks
+---------+------------------+------------+-----------+---------------------+------------------------------
+       5 |                0 |       1024 |         3 |                   0 |                            0
+(1 row)
+</screen>
+      The returned columns correspond to the fields in the
+      <structname>PageCompressHeader</structname> struct.
+      See <filename>src/include/storage/page_compression.h</filename> for details.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry>
+    <term>
+     <function>get_compress_address_items(relname text, segno integer) returns setof record</function>
+     <indexterm>
+      <primary>get_compress_address_items</primary>
+     </indexterm>
+    </term>
+
+    <listitem>
+     <para>
+      <function>get_compress_address_items</function> shows space allocation
+      information for each page of the compression relation. For example:
+<screen>
+test=# select * from get_compress_address_items('tb1',0);
+ blkno | nchunks | allocated_chunks |  chunknos
+-------+---------+------------------+------------
+     0 |       2 |                3 | {1,2,3}
+     1 |       2 |                3 | {4,5,6}
+     2 |       2 |                3 | {7,8,9}
+     3 |       2 |                3 | {10,11,12}
+     4 |       1 |                3 | {13,14,15}
+(5 rows)
+</screen>
+      The returned columns correspond to the fields in the
+      <structname>PageCompressAddr</structname> struct.
+      See <filename>src/include/storage/page_compression.h</filename> for details.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry>
+    <term>
+     <function>page_compress(page bytea, algorithm text, level integer) returns bytea</function>
+     <indexterm>
+      <primary>page_compress</primary>
+     </indexterm>
+    </term>
+
+    <listitem>
+     <para>
+      <function>page_compress</function> returns compressed content for a page.
+      It can be used to evaluate the compression ratio of a relation, based on
+      which the appropriate <xref linkend="reloption-compress-prealloc-chunks"/>
+      storage parameter can be determined.
+     </para>
+     <para>
+      A page image obtained with <function>get_raw_page</function> should be
+      passed as argument.  For example:
+<screen>
+test=# SELECT octet_length(page_compress(get_raw_page('tb1', 'main', 0), 'zstd', 0));
+ octet_length
+--------------
+         1213
+(1 row)
+</screen>
+     </para>
+    </listitem>
+   </varlistentry>
   </variablelist>
  </sect2>
 
diff --git a/doc/src/sgml/ref/create_index.sgml b/doc/src/sgml/ref/create_index.sgml
index a5bac9f737..42a68ca6a4 100644
--- a/doc/src/sgml/ref/create_index.sgml
+++ b/doc/src/sgml/ref/create_index.sgml
@@ -440,6 +440,110 @@ CREATE [ UNIQUE ] INDEX [ CONCURRENTLY ] [ [ IF NOT EXISTS ] <replaceable class=
    </varlistentry>
    </variablelist>
 
+ <para>
+    The B-tree, hash, Gin, GiST and SP-GiST index methods all
+    accept the following compression parameters:
+   </para>
+
+   <variablelist>
+   <varlistentry id="index-reloption-compresstype" xreflabel="compresstype">
+    <term><literal>compresstype</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compresstype</varname></primary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the compression method for index.
+      The supported compression methods are <literal>none</literal>,
+      <literal>pglz</literal>, <literal>lz4</literal> and
+      <literal>zstd</literal>(<literal>lz4</literal> requires PostgreSQL
+      to be compiled with <option>--with-lz4</option> and
+      <literal>zstd</literal> with <option>--with-zstd</option>).
+      And this parameter cannot be modified by <command>ALTER INDEX</command>.
+      The default is <literal>none</literal>, means do not enable compression.
+     </para>
+     <para>
+      It should be noted that freed space at the end of a compressed relation
+      cannot be released to the operating system. All space allocated to a
+      relation remains associated with that relation for reuse only within
+      that relation unless explicitly freed (for example, with
+      <command>VACUUM FULL</command> or <command>REINDEX</command>).
+      And for compressed relations, <application>pg_rewind</application> will
+      copy the entire relation files, not just the changed blocks.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry id="index-reloption-compresslevel" xreflabel="compresslevel">
+    <term><literal>compresslevel</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compresslevel</varname></primary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the compression level for a compressed relation.
+      Currently, compression level is only supported by
+      <literal>zstd</literal>, and will be ignore when use other compression
+      method. For <literal>zstd</literal> the compression level should be an
+      integer between <literal>-127</literal> and <literal>22</literal>, a
+      value greater than <literal>22</literal> will be treated as
+      <literal>22</literal>, and a value less than <literal>-127</literal> will
+      be treated as <literal>-127</literal>.
+      The default is <literal>0</literal>, means the default compression level
+      for the specific compression method. For <literal>zstd</literal>, the
+      default compression level is <literal>1</literal>.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry id="index-reloption-compress-chunk-size" xreflabel="compress_chunk_size">
+    <term><literal>compress_chunk_size</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compress_chunk_size</varname></primary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the chunk size for a compressed relation. For
+      compressed relations, storage space is allocated in chunks, and the data
+      of each block is stored in one or more chunks.
+      The chunk size must be <literal>BLCKSZ/16</literal>,
+      <literal>BLCKSZ/8</literal>, <literal>BLCKSZ/4</literal> or
+      <literal>BLCKSZ/2</literal>. For typically <symbol>BLCKSZ</symbol> of
+      <literal>8kB</literal>, the value of
+      <literal>compress_chunk_size</literal> should be one of
+      <literal>512</literal>, <literal>1024</literal>, <literal>2048</literal>
+      and <literal>4096</literal>. A smaller chunk size can achieve a higher
+      compression ratio, but it is also prone to storage fragmentation.
+      And this parameter cannot be modified by <command>ALTER INDEX</command>.
+      The default is <literal>BLCKSZ/2</literal>.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry id="index-reloption-compress-prealloc-chunks" xreflabel="compress_prealloc_chunks">
+    <term><literal>compress_prealloc_chunks</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compress_prealloc_chunks</varname></primary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the minimum number of chunks allocated for each block
+      of a compressed relation. Proper settings can effectively reduce storage
+      fragmentation, especially when
+      <xref linkend="reloption-compress-chunk-size"/> is small. The valid
+      maximum value for this parameter is
+      <literal>BLCKSZ/compress_chunk_size - 1</literal>.
+      The default is <literal>0</literal>.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   </variablelist>
+
    <para>
     B-tree indexes additionally accept this parameter:
    </para>
diff --git a/doc/src/sgml/ref/create_table.sgml b/doc/src/sgml/ref/create_table.sgml
index 6bbf15ed1a..d12f337a55 100644
--- a/doc/src/sgml/ref/create_table.sgml
+++ b/doc/src/sgml/ref/create_table.sgml
@@ -1808,6 +1808,106 @@ WITH ( MODULUS <replaceable class="parameter">numeric_literal</replaceable>, REM
     </listitem>
    </varlistentry>
 
+   <varlistentry id="reloption-compresstype" xreflabel="compresstype">
+    <term><literal>compresstype</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compresstype</varname></primary>
+     <secondary>storage parameter</secondary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the compression method for table.
+      The supported compression methods are <literal>none</literal>,
+      <literal>pglz</literal>, <literal>lz4</literal> and
+      <literal>zstd</literal>(<literal>lz4</literal> requires PostgreSQL
+      to be compiled with <option>--with-lz4</option> and
+      <literal>zstd</literal> with <option>--with-zstd</option>).
+      And this parameter cannot be modified by <command>ALTER TABLE</command>.
+      The default is <literal>none</literal>, means do not enable compression.
+     </para>
+     <para>
+      It should be noted that freed space at the end of a compressed relation
+      cannot be released to the operating system. All space allocated to a
+      relation remains associated with that relation for reuse only within
+      that relation unless explicitly freed (for example, with
+      <command>VACUUM FULL</command>).
+      And for compressed relations, <application>pg_rewind</application> will
+      copy the entire relation files, not just the changed blocks.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry id="reloption-compresslevel" xreflabel="compresslevel">
+    <term><literal>compresslevel</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compresslevel</varname></primary>
+     <secondary>storage parameter</secondary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the compression level for a compressed relation.
+      Currently, compression level is only supported by
+      <literal>zstd</literal>, and will be ignore when use other compression
+      method. For <literal>zstd</literal> the compression level should be an
+      integer between <literal>-127</literal> and <literal>22</literal>, a
+      value greater than <literal>22</literal> will be treated as
+      <literal>22</literal>, and a value less than <literal>-127</literal> will
+      be treated as <literal>-127</literal>.
+      The default is <literal>0</literal>, means the default compression level
+      for the specific compression method. For <literal>zstd</literal>, the
+      default compression level is <literal>1</literal>.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry id="reloption-compress-chunk-size" xreflabel="compress_chunk_size">
+    <term><literal>compress_chunk_size</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compress_chunk_size</varname></primary>
+     <secondary>storage parameter</secondary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the chunk size for a compressed relation. For
+      compressed relations, storage space is allocated in chunks, and the data
+      of each block is stored in one or more chunks.
+      The chunk size must be <literal>BLCKSZ/16</literal>,
+      <literal>BLCKSZ/8</literal>, <literal>BLCKSZ/4</literal> or
+      <literal>BLCKSZ/2</literal>. For typically <symbol>BLCKSZ</symbol> of
+      <literal>8kB</literal>, the value of
+      <literal>compress_chunk_size</literal> should be one of
+      <literal>512</literal>, <literal>1024</literal>, <literal>2048</literal>
+      and <literal>4096</literal>. A smaller chunk size can achieve a higher
+      compression ratio, but it is also prone to storage fragmentation.
+      And this parameter cannot be modified by <command>ALTER TABLE</command>.
+      The default is <literal>BLCKSZ/2</literal>.
+     </para>
+    </listitem>
+   </varlistentry>
+
+   <varlistentry id="reloption-compress-prealloc-chunks" xreflabel="compress_prealloc_chunks">
+    <term><literal>compress_prealloc_chunks</literal> (<type>enum</type>)
+    <indexterm>
+     <primary><varname>compress_prealloc_chunks</varname></primary>
+     <secondary>storage parameter</secondary>
+    </indexterm>
+    </term>
+    <listitem>
+     <para>
+      This parameter sets the minimum number of chunks allocated for each block
+      of a compressed relation. Proper settings can effectively reduce storage
+      fragmentation, especially when
+      <xref linkend="reloption-compress-chunk-size"/> is small. The valid
+      maximum value for this parameter is
+      <literal>BLCKSZ/compress_chunk_size - 1</literal>.
+      The default is <literal>0</literal>.
+     </para>
+    </listitem>
+   </varlistentry>
+
    </variablelist>
 
   </refsect2>
