I am trying to install chrome browser via command line. I tried this:

$ apt-cache search chrome browser

The results show that the proper term is "chrome-browser," so I tried that:

$ sudo apt-get install chrome-browser

And then "Y" for the Y/n question.

But the installation threw errors. Does someone see anything wrong with the commands I issued?

up vote 241 down vote accepted

Google Chrome isn't in the repositories - however, Chromium is.

Google Chrome is only available for 64-bit Linux. I've included directions for 64 below.

To install Google Chrome, run the following:

sudo apt-get install libxss1 libappindicator1 libindicator7
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo apt install ./google-chrome*.deb

If error messages pop up after running the command sudo apt install ./google-chrome*.deb then run the command

sudo apt-get install -f.
  • 3
    uname -i gave me x86_64 but it would seem I needed it to output amd64 instead. – altendky Aug 21 '13 at 0:07
  • 1
    I get this an ERROR 404 with these instructions. I installed using @David E. Moore instructions listed below. Not sure if adding the libxss1 helped with Mr Moore's instruction or not but I did do that before. This was on a fresh install on 13.10 Unity amd64 install. – lqlarry Oct 19 '13 at 18:28
  • 2
    What is the package libxss1 for? Is this still a requirement? – king_julien Oct 30 '13 at 11:08
  • I also had to install xdg-utils with sudo apt-get install xdg-utils – Juampy NR Nov 28 '13 at 12:19
  • 1
    @reggie done! :) – jrg Jul 9 '16 at 10:58

As per http://www.ubuntuupdates.org/ppa/google_chrome

wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add - 
sudo sh -c 'echo "deb https://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
sudo apt-get update
sudo apt-get install google-chrome-stable
  • 1
    Finally, this works on ix86 systems, thakns – radtek Nov 21 '14 at 1:38
  • 2
    This is a great answer to get the standard Google Chrome. – Mythul Mar 20 '15 at 20:01
  • 1
    This should be the accepted answer since it also pulls dependencies. – Thomas Wana May 17 at 17:31
  • after following the steps, when i run the command sudo apt-get install google-chrome-stable, "Unable to locate package google-chrome-stable" – Anurag Srivastava Oct 4 at 3:45
  • Perhaps you are using a 32-bit Ubuntu when only 64-bit is supported now, as suggested by askubuntu.com/a/853130/28107. – Dale E. Moore Oct 5 at 14:04

If you really want to install Chrome (not Chromium) using apt-get it's possible as explained here:

  • Add google repository to your sources, that is, create a new file under /etc/apt/sources.list.d with the following contents:

    deb http://dl.google.com/linux/chrome/deb/ stable main
    
  • Get repository key:

    wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
    
  • Update your sources:

    sudo apt-get update 
    
  • And install the package:

    sudo apt-get install google-chrome-stable
    

Note: instead of google-chrome-stable you can also install either google-chrome-beta or google-chrome-unstable packages from the same repository.

  • 1
    You said "create a new file under...", but what should I name that file? – user33877 Nov 14 '11 at 20:47
  • 2
    Well, the problem with this is that when you install Chrome, in theory it'll break, because Chrome's postinstall script does this for you... :) – jrg Nov 14 '11 at 20:53
  • 1
    I'd say that the name of the file isn't really important (not sure about the extension though). I'd name it google.list, but it could be chrome.list or some other random name not being already used. – jcollado Nov 14 '11 at 20:55
  • @jrg I decided to give it a try and what I found is that indeed Chrome packaging scripts add a new file under /etc/apt/sources.list.d. The result of this is that Chrome installation didn't fail, but apt-get update now prints a "duplicate sources.list entry" warning; so, yes, this method shouldn't be used unless you want to fix the sources files later. – jcollado Nov 14 '11 at 21:49
  • 6
    Here are the relevant instructions on the Google PPA page. Some of the details are now a bit different and so the above answer should be updated accordingly. – Chan-Ho Suh May 17 '12 at 23:48

If you are running a 64 Bit system, then use this:

wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb

then:

sudo dpkg -i ./google-chrome*.deb

and to finish:

sudo apt-get install -f

This is the same as jrg's reply, but you change the i386.deb to amd64.deb.

EDIT: The past couple of times I have not had to do the install -f. It seems to have all needed after installing.

Good Luck!!

  • Jorge added this to the accepted answer above. I guess I should of thought of that. Makes the answer more complete now. – lqlarry Nov 20 '11 at 3:12
  • Yes, thank you. – user33877 Nov 20 '11 at 12:27
  • Is the line sudo apt-get install -f really necessary? – king_julien Oct 30 '13 at 11:27
  • 1
    I think my answer is outdated. I've used the answer above mine (at this time) by @Dale E. Moore and had successful installs. – lqlarry Nov 4 '13 at 3:19
  • Your answer is not outdated. The google-chrome-stable_current_amd64.deb will remain current (by its namesake) as long as it's being maintained and updated by Google. On rare occasions, just like any manual install, you might have to use the install -f option. But as of Ubuntu 18.04, it installs the absolute latest Chrome update and configures it to be automatically flagged for regular updates when they are available. The two commands are the cleanest and easiest method of a fresh install of Google Chrome. – L. D. James Jun 16 at 8:53

If you want the official Google Chrome build, you have to download it from here: Download Google Chrome.

I believe only Chromium is in the repository.

wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add - 
sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
sudo apt-get update 
sudo apt-get install google-chrome-stable 

that's correct code for ubuntu :)

If you want Google Chrome, just search it in google. If you want Chromium add this ppa:

sudo add-apt-repository ppa:chromium-daily/stable
sudo apt-get update
sudo apt-get install chromium-browser

And that's it. Enjoy your browser.

  • 8
    -1, daily builds aren't recommended for anyone other than developers. THIS IS DANGEROUS. – jrg Nov 14 '11 at 20:43
  • 1
    What PPA should be added? If you cannot answer this question now you can delete your answer, and gain back 2 rep. – hexafraction Oct 3 '12 at 20:45

protected by Community Mar 9 '14 at 9:55

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?