Mute and set volume with `pactl` from the command line

The overlooked built-in for controlling audio without the desktop applet — perfect for scripts, hotkeys and over SSH, and it works on PipeWire too.

LinuxaudiopactlpulseaudiovolumeLow risk
Run `pactl set-sink-mute @DEFAULT_SINK@ toggle` to mute/unmute the default output, or `pactl set-sink-volume @DEFAULT_SINK@ 75%` to set its volume.

01Command

Command
$ pactl set-sink-mute @DEFAULT_SINK@ toggle

02What it does

pactl speaks the PulseAudio protocol; PipeWire's compatibility layer implements it, so the same commands work on modern distros. `@DEFAULT_SINK@` targets whatever output is currently default — otherwise list sinks with `pactl list sinks short` and use the name. Other forgotten gems: `pactl set-sink-volume @DEFAULT_SINK@ +10%` and `-10%` for relative changes, and `pactl set-source-mute @DEFAULT_SOURCE@ toggle` for the microphone.

03Risk

RiskLow risk
RequirementsRequires PulseAudio or PipeWire with pactl (preinstalled on Ubuntu, Fedora and most desktop distros)

04Undo

Undo
$ pactl set-sink-mute @DEFAULT_SINK@ 0

05Sources

  • pactl(1) — control a running PulseAudio sound server
    Ubuntu Manpages · technical · 2026-09-17
    Evidence: Documents set-sink-mute SINK 1|0|toggle, set-sink-volume with percentages, and the @DEFAULT_SINK@ alias
  • PulseAudio — ArchWiki
    ArchWiki · community · 2026-09-17
    Evidence: Shows pactl one-liners for muting and volume control, including use under PipeWire's PulseAudio compatibility layer

Last verified: 2026-09-17 · Category: Media