> For the complete documentation index, see [llms.txt](https://docs.postgresql.tw/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.postgresql.tw/reference/reference-client.md).

# PostgreSQL Client Applications

***

This part contains reference information for PostgreSQL client applications and utilities. Not all of these commands are of general utility; some might require special privileges. The common feature of these applications is that they can be run on any host, independent of where the database server resides.

When specified on the command line, user and database names have their case preserved — the presence of spaces or special characters might require quoting. Table names and other identifiers do not have their case preserved, except where documented, and might require quoting.

**Table of Contents**

[clusterdb](/reference/reference-client/app-clusterdb.md) — cluster a PostgreSQL database

[createdb](/reference/reference-client/app-createdb.md) — create a new PostgreSQL database

[createuser](/reference/reference-client/app-createuser.md) — define a new PostgreSQL user account

[dropdb](/reference/reference-client/app-dropdb.md) — remove a PostgreSQL database

[dropuser](/reference/reference-client/app-dropuser.md) — remove a PostgreSQL user account

[ecpg](/reference/reference-client/app-ecpg.md) — embedded SQL C preprocessor

[pg\_amcheck](/reference/reference-client/app-pgamcheck.md) — checks for corruption in one or more PostgreSQL databases

[pg\_basebackup](/reference/reference-client/app-pgbasebackup.md) — take a base backup of a PostgreSQL cluster

[pgbench](/reference/reference-client/pgbench.md) — run a benchmark test on PostgreSQL

[pg\_combinebackup](/reference/reference-client/app-pgcombinebackup.md) — reconstruct a full backup from an incremental backup and dependent backups

[pg\_config](/reference/reference-client/app-pgconfig.md) — retrieve information about the installed version of PostgreSQL

[pg\_dump](/reference/reference-client/app-pgdump.md) — export a PostgreSQL database as an SQL script or to other formats

[pg\_dumpall](/reference/reference-client/app-pg-dumpall.md) — extract a PostgreSQL database cluster into a script file

[pg\_isready](/reference/reference-client/app-pg-isready.md) — check the connection status of a PostgreSQL server

[pg\_receivewal](/reference/reference-client/app-pgreceivewal.md) — stream write-ahead logs from a PostgreSQL server

[pg\_recvlogical](/reference/reference-client/app-pgrecvlogical.md) — control PostgreSQL logical decoding streams

[pg\_restore](/reference/reference-client/app-pgrestore.md) — restore a PostgreSQL database from an archive file created by pg\_dump

[pg\_verifybackup](/reference/reference-client/app-pgverifybackup.md) — verify the integrity of a base backup of a PostgreSQL cluster

[psql](/reference/reference-client/app-psql.md) — PostgreSQL interactive terminal

[reindexdb](/reference/reference-client/app-reindexdb.md) — reindex a PostgreSQL database

[vacuumdb](/reference/reference-client/app-vacuumdb.md) — garbage-collect and analyze a PostgreSQL database

***

原文：[PostgreSQL 18.6 Documentation](https://www.postgresql.org/docs/18/reference-client.html)（英文原文，待翻譯）


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.postgresql.tw/reference/reference-client.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
