Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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

Every time I click a link in emacs, it opens Firefox (I'm running Ubuntu). I'd like to replace that with Chrome.

I've tried

(setq browse-url-browser-function 'browse-url-generic browse-url-generic-program "google-chrome")

as per but it does not work for me.

Emacs version: GNU Emacs 23.1.1 (x86_64-pc-linux-gnu, GTK+ Version 2.20.1) of 2011-03-04 on allspice, modified by Debian

share|improve this question
That solution works for me, did you put (setq ...) to your ~/.emacs? – cYrus Feb 13 '12 at 18:00
Could you please include your emacs version? – N.N. Feb 13 '12 at 20:12
@cYrus yes I did put it in my .emacs – I82Much Feb 14 '12 at 0:50

might try the solution here

summary: write a command that makes a shell call to launch chrome executable with a url.

share|improve this answer

If Chrome is configured as your default desktop browser you may be able to launch it using xdg-open by putting

(setq browse-url-browser-function 'browse-url-generic browse-url-generic-program "gnome-open")

in your .emacs.

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.