Sign up ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

How do you mute the sound system from the command line?

share|improve this question
Works perfectly with the i3 window manager. Thanks a lot! –  user315729 Aug 14 '14 at 18:42

4 Answers 4

up vote 42 down vote accepted

Assuming you're using ALSA driver, run:

amixer set Master mute   
amixer set Master unmute

Or, you can just use:

amixer set Master toggle

to toggle mute on and off.

share|improve this answer
for me / my system (precise), this only goes one way: off / mute. Neither toggle nor unmute bring the music back on. Any ideas as to why?? –  nutty about natty May 8 '12 at 13:12

On the terminal type this to mute

amixer set Master mute


amixer set Master unmute

Tested on my Ubuntu 10.10.

PS: +1 for interesting question.

share|improve this answer

This worked for me when others didn't:

amixer -q -D pulse sset Master toggle

This is from the link in nutty about natty's comment to the first answer:

share|improve this answer
Thanks! This works for me on Ubuntu 12.04. –  Kamil Slowikowski May 30 '14 at 2:53
I also just checked, it works on 14.04 too. –  Tim May 30 '14 at 8:59
did it :) - kubuntu here (Ubuntu 14.04.2 LTS). thx. –  hakre Jul 2 at 18:28

In my setup sometimes amixer unmute fails for some reason. Therefore I'm using pactl in my scripts:

to mute:

pactl set-sink-mute 0 1

and unmute:

pactl set-sink-mute 0 0

Tested on Ubuntu 12.10.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.