---
name: "public-inbox-purge"
section: "1"
platform: "linux"
package: "public-inbox"
version: "1.9.0-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/public-inbox-purge"
---

# public-inbox-purge(1)

erase messages from a public inbox and its history

## NAME

public-inbox-purge - erase messages from a public inbox and its history

## SYNOPSIS

```
        # requires ~/.public-inbox/config
        public-inbox-purge --all </path/to/message-to-purge
        # for testing with unconfigured inboxes:
        public-inbox-purge $INBOX_DIR </path/to/message-to-purge
```

## DESCRIPTION

public-inbox-purge allows removing entire messages in a given inbox from history.  It is only intended as a last resort, as it will cause discontiguous git history and draw more attention to the sensitive data in mirrors.

For removing spam, [**public-inbox-learn**(1)](/public-inbox-learn/1.md) is preferable as it preserves contiguous git history.

For editing sensitive information out of messages, consider [**public-inbox-edit**(1)](/public-inbox-edit/1.md), instead, but keep in mind it still leads to discontiguous git history.

## OPTIONS

- \--all

  Purge the message in all inboxes configured in ~/.public-inbox/config. This is an alternative to specifying individual inboxes directories on the command-line.

## ENVIRONMENT

- PI\_CONFIG

  The default config file, normally "~/.public-inbox/config". See [**public-inbox-config**(5)](/public-inbox-config/5.md)

## LIMITATIONS

Only [**public-inbox-v2-format**(5)](/public-inbox-v2-format/5.md) inboxes are supported.

This is safe to run while normal inbox writing tools ([**public-inbox-mda**(1)](/public-inbox-mda/1.md), [**public-inbox-watch**(1)](/public-inbox-watch/1.md), [**public-inbox-learn**(1)](/public-inbox-learn/1.md)) are active.

Running this in parallel with [**public-inbox-xcpdb**(1)](/public-inbox-xcpdb/1.md) or `"public-inbox-index --reindex"` can lead to errors or purged data remaining indexed.

Incremental [**public-inbox-index**(1)](/public-inbox-index/1.md) (without `"--reindex"`) is fine.

Keep in mind this is a last resort, as it will be disruptive to anyone using [**git**(1)](/git/1.md) to mirror the inbox being purged.

## CONTACT

Feedback welcome via plain-text mail to \<mailto:meta@public-inbox.org\>

The mail archives are hosted at \<https://public-inbox.org/meta/\> and \<http://4uok3hntl7oi7b4uf4rtfwefqeexfzil2w6kgk2jn5z2f764irre7byd.onion/meta/\>

## COPYRIGHT

Copyright 2019-2021 all contributors \<mailto:meta@public-inbox.org\>

License: AGPL-3.0+ \<https://www.gnu.org/licenses/agpl-3.0.txt\>

## SEE ALSO

[**public-inbox-edit**(1)](/public-inbox-edit/1.md), [**public-inbox-learn**(1)](/public-inbox-learn/1.md)
