> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pgxman.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Uninstalling

## Optional: remove extensions

Note that extensions you have installed will continue to work even if you
remove the `pgxman` CLI.

1. Use [DROP EXTENSION][drop extension] to remove any installed extensions
   from your Postgres databases.
2. Uninstall extensions by running
   `apt remove postgresql-$VERSION-pgxman-$EXTNAME`.
   You can get a list of installed extensions with the command
   `apt list --installed | grep pgxman`.

[drop extension]: https://www.postgresql.org/docs/current/sql-dropextension.html

## Remove pgxman

This will depend on how you installed pgxman.

* If you used the shell script, it installs pgxman via your package manager.
  * Linux: `apt remove pgxman`
  * MacOS: `brew remove pgxman`
* If you installed pgxman via homebrew: `brew remove pgxman`
* If you installed the binary manually into your path, use `which pgxman` to
  locate the binary, then `rm` it.

## Remove pgxman config directory

This directory is located in your [user config directory][].

* Linux: `~/.config/pgxman`
* MacOS: `~/Library/Application Support/pgxman`

You can remove the directory using `rm -r`:

```sh theme={null}
rm -r ~/.config/pgxman
```

[user config directory]: https://pkg.go.dev/os#UserConfigDir
