# Install ansifilter with Homebrew, apk, apt, dnf, MacPorts, Nix, zypper

Strip or convert ANSI codes into HTML, (La)Tex, RTF, or BBCode. Version 2.22 via Homebrew; verified from local package data.

## Install

```sh
sudo av install brew:ansifilter
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install ansifilter
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install ansifilter
```

  Evidence: MacPorts ports tree: textproc/ansifilter/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add ansifilter
```

  Evidence: Alpine Linux edge package indexes: ansifilter from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install ansifilter
```

  Evidence: Debian stable package indexes: ansifilter from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install ansifilter
```

  Evidence: Fedora Rawhide package metadata: ansifilter from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#ansifilter
```

  Evidence: nixpkgs package indexes: pkgs/by-name/an/ansifilter/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- zypper (92%):

```sh
sudo zypper install ansifilter
```

  Evidence: openSUSE Tumbleweed package metadata: ansifilter from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst

## Package facts

- **Package key:** brew:ansifilter
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/ansifilter>
- **Version:** 2.22
- **Source summary:** Strip or convert ANSI codes into HTML, (La)Tex, RTF, or BBCode
- **Homepage:** <http://andre-simon.de/doku/ansifilter/en/ansifilter.php>
- **Repository:** <https://gitlab.com/saalen/ansifilter>
- **Upstream docs:** <http://andre-simon.de/doku/ansifilter/en/ansifilter.php>
- **License:** GPL-3.0-or-later
- **Source archive:** <https://gitlab.com/saalen/ansifilter/-/archive/2.22/ansifilter-2.22.tar.bz2>
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- ansifilter (cli)
- ansifilter (alias)

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, arm64_ventura, sonoma, ventura, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 2.22
- Local data: ok
- Upstream repository: http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- info: No package-manager update timestamp was available.
- info: Release/tag comparison is only available for GitHub repositories.
## Project history and usage

ansifilter is a small command-line converter for text containing ANSI terminal escape sequences. It can strip escape codes or interpret them into formatted output such as HTML, RTF, TeX, LaTeX, BBCode, Pango Markup, and SVG.

### Project history

The official changelog starts with ansifilter 0.1 on 25 October 2007. Early releases focused on terminal color escape handling, including xterm 256-color support by 1.0 in 2008 and license migration from GPLv2 to GPLv3 in 2009.

The tool gradually expanded from a filter into a format bridge. LaTeX, TeX, BBCode, Pango, SVG, true color, OSC 8 hyperlinks, and ANSI-art formats were added over time, while the README documents a single CLI that can read stdin or files and produce multiple markup formats.

### Adoption history

ansifilter appears in many Unix package managers because it solves a packaging-adjacent problem: converting colorized CLI output into archival or publishable text. Its changelog references contributions and fixes from distro and user communities, including Portage warning fixes, shell completion scripts, and issues from both its older GitHub tracker and current GitLab tracker.

### How it is used

Typical use is pipeline-oriented: pass colorized command output through ansifilter to strip ANSI escapes, or choose an output format such as --html, --latex, --rtf, --svg, or --bbcode. The README also documents --tail for following log files and ANSIFILTER_OPTIONS for default CLI options.

For package users, ansifilter is a handy companion to grep, test logs, CI logs, terminal captures, and ANSI-art files. It is deliberately not a credentials-bearing tool and has no documented default config file.

### Why package nerds care

Package nerds care about ansifilter because it lives at the boundary between terminals and documentation. It turns the color and formatting conventions emitted by Unix commands into artifacts suitable for web pages, bug reports, manuals, and forums without dragging in a full terminal emulator.

### Timeline

- 2007: Initial ansifilter 0.1 release.
- 2008: ansifilter 1.0 adds xterm 256-color sequence support.
- 2009: License changes from GPLv2 to GPLv3.
- 2016: ansifilter 2.0 adds a new CSI parser and ANSI/BIN/XBIN art options.
- 2019: ansifilter 2.14 adds SVG output.
- 2021: ansifilter 2.18 adds OSC 8 hyperlink support.
- 2025: ansifilter 2.22 adds tee and append-oriented CLI output features.

### Related projects

- highlight is another Andre Simon project focused on source-code highlighting rather than ANSI escape conversion.
- Terminal log renderers and CI systems often need similar ANSI stripping or HTML conversion behavior.

### Sources

- <https://gitlab.com/saalen/ansifilter/-/raw/master/ChangeLog.adoc>
- <https://gitlab.com/saalen/ansifilter/-/raw/master/README.adoc>
- source_facts.package-manager


## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** ansifilter
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## Other Package-Manager Records

- Debian apt - ansifilter - 2.21-1: normalized package name match | Debian stable package indexes: ansifilter from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | parse common (terminal) ANSI codes and remove or convert them | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- Debian apt - ansifilter-gui - 2.21-1: normalized package name match | Debian stable package indexes: ansifilter-gui from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | parse common (terminal) ANSI codes and remove or convert them (GUI) | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- Nix - ansifilter: normalized package name match | nixpkgs package indexes: pkgs/by-name/an/ansifilter/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - ansifilter - 2.18+dfsg1-2build2: normalized package name match | Ubuntu 24.04 LTS package indexes: ansifilter from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | parse common (terminal) ANSI codes and remove or convert them | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- Ubuntu apt - ansifilter-gui - 2.18+dfsg1-2build2: normalized package name match | Ubuntu 24.04 LTS package indexes: ansifilter-gui from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | parse common (terminal) ANSI codes and remove or convert them (GUI) | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- apk - ansifilter - 2.22-r0: normalized package name match | Alpine Linux edge package indexes: ansifilter from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Convert text files containing ANSI terminal escape codes to a variety of output formats | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- apk - ansifilter-bash-completion - 2.22-r0: normalized package name match | Alpine Linux edge package indexes: ansifilter-bash-completion from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Bash completions for ansifilter | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- apk - ansifilter-doc - 2.22-r0: normalized package name match | Alpine Linux edge package indexes: ansifilter-doc from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Convert text files containing ANSI terminal escape codes to a variety of output formats (documentation) | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- apk - ansifilter-fish-completion - 2.22-r0: normalized package name match | Alpine Linux edge package indexes: ansifilter-fish-completion from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Fish completions for ansifilter | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- apk - ansifilter-zsh-completion - 2.22-r0: normalized package name match | Alpine Linux edge package indexes: ansifilter-zsh-completion from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Zsh completions for ansifilter | http://andre-simon.de/doku/ansifilter/en/ansifilter.php
- dnf - ansifilter - 2.22-4.fc45: normalized package name match | Fedora Rawhide package metadata: ansifilter from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | ANSI terminal escape code converter | http://www.andre-simon.de/doku/ansifilter/ansifilter.php
- dnf - ansifilter-gui - 2.22-4.fc45: normalized package name match | Fedora Rawhide package metadata: ansifilter-gui from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | GUI for ansifilter based on Qt6 | http://www.andre-simon.de/doku/ansifilter/ansifilter.php
- zypper - ansifilter - 2.22-1.4: normalized package name match | openSUSE Tumbleweed package metadata: ansifilter from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | ANSI Terminal Escape Code Converter | http://www.andre-simon.de/
- zypper - ansifilter-gui - 2.22-1.4: normalized package name match | openSUSE Tumbleweed package metadata: ansifilter-gui from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | ANSI Terminal Escape Code Converter - Qt GUI | http://www.andre-simon.de/
- MacPorts - ansifilter: normalized package name match | MacPorts ports tree: textproc/ansifilter/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Related links

- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [aha](https://www.automicvault.com/pkg/brew/aha/) - Shares av.db curated category or tags: ansi, cli, developer-tools, html, terminal.
- [sequin](https://www.automicvault.com/pkg/brew/sequin/) - Shares av.db curated category or tags: ansi, cli, developer-tools, terminal.
- [amtterm](https://www.automicvault.com/pkg/brew/amtterm/) - Shares av.db curated category or tags: cli, developer-tools, terminal.
- [ccat](https://www.automicvault.com/pkg/brew/ccat/) - Shares av.db curated category or tags: cli, developer-tools, terminal.
- [clive](https://www.automicvault.com/pkg/brew/clive/) - Shares av.db curated category or tags: cli, developer-tools, terminal.
- [colordiff](https://www.automicvault.com/pkg/brew/colordiff/) - Shares av.db curated category or tags: cli, developer-tools, terminal.
- [colormake](https://www.automicvault.com/pkg/brew/colormake/) - Shares av.db curated category or tags: cli, developer-tools, terminal.
- [et](https://www.automicvault.com/pkg/brew/et/) - Shares av.db curated category or tags: cli, developer-tools, terminal.
- [highlight](https://www.automicvault.com/pkg/brew/highlight/) - Both packages work with overlapping file formats or content types. Shared terms: cli, convert, developer, developer-tools, html.

## Combined YAML source

View the package source record on GitHub. [combined/ansifilter.yml](https://github.com/automic-vault/db/blob/main/combined/ansifilter.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
