# CAVA

> Cross-platform bar spectrum audio visualizer for the terminal or SDL desktop window, with PipeWire, PulseAudio, ALSA, JACK and other input backends.

Stars: 6.5k · Language: C · License: MIT · Categories: System

- Repository: https://github.com/karlstav/cava
- Page: https://www.trmn.sh/tools/cava

## Install

- Homebrew: `brew install cava`
- apt: `sudo apt install cava`
- pacman: `pacman -S cava`

## Overview

CAVA (Cross-platform Audio Visualizer) is a bar spectrum audio visualizer that renders in a terminal or in a desktop window via SDL. It runs on Linux, FreeBSD, macOS and Windows, and the README notes that it also supports dumb terminals. It is built to look responsive when visualizing music and is explicitly not intended for scientific use.

Audio input is selected with the `method` option in the config file. Supported backends are PipeWire (the default where supported), PulseAudio, ALSA, sndio, OSS, JACK, portaudio, squeezelite, and a fifo input for sources such as MPD. On macOS, Core Audio is supported without extra capture libraries. The README documents backend-specific setup, for example creating an ALSA loopback interface with `modprobe snd_aloop`, or adding a fifo `audio_output` block to mpd and setting `source` to the fifo path.

CAVA can be built from source with autotools (`./autogen.sh`, `./configure`, `make`), which requires FFTW, iniparser and build tools. CMake is used on Windows. Ncurses is available as an alternative output method. Beyond standalone use, the audio processing is available as the cavacore library, and CAVA can emit raw output for other applications. It suits terminal users, ricers and people who want a music visualizer running alongside a player.

### Installation

```bash
# via Homebrew
brew install cava
```

```bash
# via apt
sudo apt install cava
```

```bash
# via pacman
pacman -S cava
```

![CAVA spectrum visualizer](https://media.trmn.sh/cached/b664adc96485b1f7498d948f460699f33007e4b2d406e980a79e35079eeea815.gif)

## Alternatives

- [cmus](https://www.trmn.sh/tools/cmus.md): Console music player for Unix-like systems with ncurses interface and optional input/output plugins for many audio formats and backends. (C, 6.3k stars)
- [htop](https://www.trmn.sh/tools/htop.md): Cross-platform interactive process viewer with real-time system monitoring and process management (C, 8.4k stars)
- [nvtop](https://www.trmn.sh/tools/nvtop.md): htop-like GPU and accelerator task monitor supporting NVIDIA, AMD, Intel, Apple, and other vendors (C, 11.1k stars)
- [GoAccess](https://www.trmn.sh/tools/goaccess.md): Real-time web server log analyzer written in C that shows HTTP statistics in a terminal or a live HTML dashboard, with JSON and CSV export. (C, 21.1k stars)
- [fastfetch](https://www.trmn.sh/tools/fastfetch.md): System information tool that displays hardware and OS details with customizable ASCII art logos and module configuration (C, 25.2k stars)

---

Canonical: https://www.trmn.sh/tools/cava
