Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using Ubuntu 10.04 with Fluxbox.

Since I installed Chromium-browser, it has been set as the default system browser (don't know why, don't know when, maybe I clicked accept somewhere without paying attention). Now every web link I click (for example from Skype), Chromium will be opened instead of Firefox.

How can I make Firefox my system default browser?

I need to set this preference using the command line.

share|improve this question
@slhck: not exactly.. i need to do this from command line – Heisenbug May 10 '11 at 11:04
Oh, then we'll make that more clear :) – slhck May 10 '11 at 11:06
up vote 18 down vote accepted

From the terminal, use

sudo update-alternatives --config x-www-browser

This will provide a list of installed browsers, similar to the following (which is mine):

There are two alternatives which provide `x-www-browser'.
Selection    Path                         Priority    Status
* 1          /usr/bin/chromium-browser    40          auto mode
  2          /usr/bin/firefox             40          manual mode

Press enter to keep the current choice[*], or type selection number:

Just hit the selection number for the browser you want.

share|improve this answer
Happy to, I'll edit it in now. – Lukasa May 10 '11 at 11:20
Thank you, +1 for you. – slhck May 10 '11 at 11:29
And how can I change the default browser to "Chromium" always using bash, without getting its number first? – Mathias Lykkegaard Lorenzen Jul 31 '13 at 16:41
@MathiasLykkegaardLorenzen sudo update-alternatives --set x-www-browser /usr/bin/chromium-browser, there is also a command to list all alternatives in the form of --list name. Check out the manpage. – Winny Aug 10 '15 at 4:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .