Install Google Chrome Ubuntu Command Line

7 min read

Install Google Chrome Ubuntu Command Line: A Step‑by‑Step Guide

Google Chrome remains one of the most popular web browsers thanks to its speed, extensive extension library, and seamless synchronization across devices. Installing Google Chrome on Ubuntu via the command line is straightforward, and doing so gives you full control over the process, making it ideal for headless servers, remote machines, or automated deployment scripts. While Ubuntu ships with Firefox as the default browser, many users prefer Chrome for its compatibility with certain web apps and its familiar interface. This guide walks you through every step, from preparing your system to verifying the installation and troubleshooting common issues.


Why Choose the Command Line Installation?

Using the terminal to install Google Chrome offers several advantages:

  • Speed and efficiency – No need to handle graphical menus; a few commands accomplish the task.
  • Reproducibility – You can embed the commands in scripts or documentation for consistent setups across multiple machines.
  • Minimal dependencies – The process relies only on wget (or curl) and dpkg, which are present on virtually every Ubuntu installation.
  • Control over version – You can explicitly download the latest stable release or a specific version if needed.

Prerequisites

Before you begin, ensure your system meets the following requirements:

  1. Ubuntu version – This guide works on Ubuntu 20.04 LTS, 22.04 LTS, and later releases. Older versions may lack required libraries.
  2. Administrative privileges – You need sudo access to install packages.
  3. Internet connectivity – The installer downloads the .deb package directly from Google’s servers.
  4. Basic tools – wget or curl should be installed. If not, install them with sudo apt update && sudo apt install wget -y.

Step‑by‑Step Installation Process

1. Update Package Index

Start by refreshing your local package list to avoid conflicts with outdated repositories That's the whole idea..

sudo apt update

2. Download the Google Chrome .deb Package

Google provides a Debian package for Chrome that can be fetched directly. Use wget (or curl) to download the latest stable release for 64‑bit Linux That alone is useful..

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

If you prefer curl, the equivalent command is:

curl -L -O https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb

The file will appear in your current directory as google-chrome-stable_current_amd64.deb Which is the point..

3. Install the Package with dpkg

dpkg handles the installation of Debian packages. Run it with sudo to grant the necessary permissions.

sudo dpkg -i google-chrome-stable_current_amd64.deb

During this step you may see output indicating that the package was unpacked and configured. If there are missing dependencies, dpkg will report errors but will not halt the process.

4. Resolve Missing Dependencies (If Any)

If dpkg complains about unmet dependencies, fix them with the following command:

sudo apt --fix-broken install -y

APT will automatically install any required libraries (such as libxss1, libappindicator1, or fonts-liberation) and complete the Chrome setup.

5. Verify the Installation

Once the installation finishes, confirm that Google Chrome is available and functional Not complicated — just consistent..

google-chrome --version

You should see output similar to:

Google Chrome 124.0.6367.91

To launch the browser from the terminal, simply type:

google-chrome &

The ampersand sends the process to the background, allowing you to continue using the terminal Worth keeping that in mind. No workaround needed..


Post‑Installation Tips

Setting Chrome as the Default Browser

If you want Chrome to open links automatically, set it as the default:

sudo update-alternatives --install /usr/bin/x-www-browser x-www-browser /usr/bin/google-chrome 200
sudo update-alternatives --set x-www-browser /usr/bin/google-chrome

Keeping Chrome Updated

Google’s repository is not added automatically by the .deb package. To receive future updates via apt, add Google’s official signing key and repository:

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

Now you can upgrade Chrome alongside other system packages:

sudo apt upgrade google-chrome-stable

Removing Chrome (If Needed)

Should you ever need to uninstall Chrome, use:

sudo apt purge google-chrome-stable
sudo rm -rf /home/$USER/.config/google-chrome

The second command deletes the user profile data, including bookmarks and history.


Troubleshooting Common Issues

Symptom Likely Cause Solution
**`dpkg: error processing archive google-chrome-stable_current_amd64.Day to day,
Unable to add Google’s repository due to GPG key error Outdated or missing key. Also, Reinstall the package or manually symlink: sudo ln -s /opt/google/chrome/google-chrome /usr/bin/google-chrome. On top of that,
google-chrome: command not found after installation The binary is not in your $PATH (rare, but possible if installation was interrupted). Run sudo apt --fix-broken install -y to let APT fetch the required packages.
Chrome launches but crashes immediately Incompatible graphics drivers or missing libnss3. Update graphics drivers (sudo apt upgrade) and ensure libnss3 is installed (sudo apt install libnss3).
Dependency errors after dpkg -i Missing libraries such as libxss1 or libgconf-2-4. Retrieve the key again as shown in the “Keeping Chrome Updated” section.

If you encounter a problem not listed here, consult the terminal output carefully; it often contains hints about missing packages or permission issues Worth knowing..


Security and Privacy Considerations

While Chrome provides a reliable browsing experience, keep these points in mind:

  • Automatic updates – Adding Google’s repository ensures you receive security patches promptly.

  • Sandboxing – Chrome runs each tab in a separate sandbox, limiting the impact of malicious websites Simple, but easy to overlook..

  • Data sync – If you enable sync, your bookmarks, history, and passwords are stored on Google’s servers. Review your sync settings under Settings > You and Google > Sync and Google services.

  • Privacy controls – Chrome includes a built-in privacy guide (Settings > Privacy and security > Privacy guide) that walks you through managing cookies, site data, and tracking prevention. Consider enabling "Enhanced tracking prevention" for an extra layer of defense.

  • Extensions – Be cautious with browser extensions, as they can request extensive permissions. Stick to well-reviewed extensions from the Chrome Web Store and regularly review your installed ones.

  • Incognito mode – Use this for private browsing sessions. Note that while it prevents Chrome from saving your history and cookies, your Internet Service Provider and the websites you visit can still track your activity That's the part that actually makes a difference..


Alternatives to Chrome

If you're looking for a different browsing experience, here are a few alternatives available in the Debian/Ubuntu repositories:

  • Firefox – Known for its customization options and strong privacy stance. Install with sudo apt install firefox.
  • Brave – Focuses on privacy and speed, blocking ads and trackers by default. Add Brave's repository for installation instructions on their official site.
  • Chromium – The open-source project that Chrome is based on, without the proprietary components and Google integration. Install with sudo apt install chromium.

Each browser has its own strengths, so it's worth trying a few to see which fits your needs best No workaround needed..


Final Thoughts

Installing Google Chrome on Debian or Ubuntu is a straightforward process that can be kept up-to-date with minimal effort once the Google repository is added. While Chrome offers a feature-rich and secure browsing experience, it helps to be mindful of privacy settings and data sync if those are concerns for you Which is the point..

By following the steps outlined in this guide, you should have Chrome running smoothly on your system, with the ability to troubleshoot common issues and make informed decisions about your browsing setup. Whether you stick with Chrome or explore alternatives, the key is to choose a browser that aligns with your workflow and security preferences.

Happy browsing!

Hot and New

Recently Written

People Also Read

While You're Here

Thank you for reading about Install Google Chrome Ubuntu Command Line. We hope the information has been useful. Feel free to contact us if you have any questions. See you next time — don't forget to bookmark!
⌂ Back to Home