Every Ubuntu user that uses a graphical interface will have to interact with Mozilla Firefox in some capacity, since it’s the default internet browser on Ubuntu 22.04 Jammy Jellyfish. Even if you just want to uninstall it and use a different browser, you’ll at least be dealing with it for a short time. In this guide, we’ll show you how you can install, update, and uninstall Firefox on Ubuntu 22.04.
In this tutorial you will learn:
- How to install, update, and uninstall Firefox with Ubuntu’s default package repository
- How to install, update, and uninstall Firefox with Mozilla PPA repository
- How to install, update, and uninstall Firefox with direct download
|Category||Requirements, Conventions or Software Version Used|
|System||Ubuntu 22.04 Jammy Jellyfish|
|Other||Privileged access to your Linux system as root or via the
# – requires given linux commands to be executed with root privileges either directly as a root user or by use of
$ – requires given linux commands to be executed as a regular non-privileged user
How to install Firefox
As we mentioned earlier, Firefox is the default internet browser on Ubuntu 22.04. Therefore, it stands to reason that it’s already on your system and there’s no need for installation instructions, right? Yeah, probably. But you or someone else may decide to uninstall it and come back to it later, or maybe it’s giving you problems and you want to reinstall the software altogether. We’ll show you a few methods for how to install, update, and uninstall Firefox from your system in this section.
There are three ways we can install Firefox. All of them accomplish the same thing, but you should pick the one that best suits you:
- Installing from the Standard Ubuntu repository – this involves using an
aptcommand to install a stable version of Firefox. Use this method if you’re in a hurry or unsure of which method to use.
- Installing from the Mozilla PPA repository. This is another command line method but it allows you to install more updated (and less stable, possibly) versions of Firefox directly from Mozilla’s repository. Use this method if you enjoy the bleeding edge.
- Installing from Firefox’s official website, Mozilla.org. We’ll show how to do this from the command line with wget, but you can also use this method if you want to avoid the command line and you already have a browser that can be used to navigate to Firefox’s website.
We’re going to show you the step by step for each of these methods, and regardless of which one you choose, you’ll be able to follow along with our instructions to update and uninstall Firefox as well.
First thing’s first. You should open a command line terminal and run a quick couple Linux commands to update your system’s apt index and see if a current version of Firefox is already installed on your system:
$ sudo apt update $ firefox --version
With that out of the way, it’s time to pick a method and follow one of the sections below to get Firefox installed or updated.
Install, update, and uninstall Firefox from Ubuntu repository
The following section will explain how to install, update, and uninstall Mozilla Firefox from the command line, using Ubuntu’s default package repository.
If the Firefox browser isn’t already on your Ubuntu 22.04 system for some reason, entering the following command in a terminal will download and install it:
$ sudo apt install firefox
The same command will also update Firefox if it’s already installed:
$ sudo apt update $ sudo apt install firefox
However, if you want to update the browser, we’d recommend that you just upgrade your Ubuntu operating system entirely. This will update all of your installed packages rather than just the single Firefox package.
$ sudo apt upgrade
To uninstall Firefox from your system, we’ll use another
apt command. This command will remove Firefox from your system:
$ sudo apt remove firefox
Install, update, and uninstall Firefox from Mozilla PPA repository
The following section will explain how to install, update, and uninstall Mozilla Firefox from the command line, using the Mozilla developer PPA repository. Remember that this method will install the latest version of Firefox, even if it’s in beta and considered a little less than stable.
- First, we need to add the Mozilla signing key to our system:
$ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A6DCF7707EBC211F
- Next, add Mozilla’s PPA repository and update the list of available packages in
$ sudo apt-add-repository "deb http://ppa.launchpad.net/ubuntu-mozilla-security/ppa/ubuntu jammy main" $ sudo apt update
- Finally, if all went well up till now, install the latest version of Firefox with this command:
$ sudo apt install firefox
You can still uninstall Firefox in the traditional way, with
apt at the command line:
$ sudo apt remove firefox
Install, update, and uninstall Firefox with direct download
The following section will explain how to install, update, and uninstall Mozilla Firefox from the command line, using the official Mozilla website. If you already have an alternative browser installed on your system and you’re not the type who likes to fiddle with the command line, remember that you can just navigate to Mozilla.org and download the installation file.
wgetto download the latest version of Firefox directly from Mozilla’s website into your user’s home directory:
$ wget -O ~/FirefoxSetup.tar.bz2 "https://download.mozilla.org/?product=firefox-latest&os=linux64"
- Next, extract the Firefox package to your system’s
$ sudo tar xjf ~/FirefoxSetup.tar.bz2 -C /opt/
- It’s a good idea to make a backup of the original Firefox binary executable in case we need to switch back to the default Ubuntu Firefox version:
$ sudo mv /snap/bin/firefox /snap/bin/firefox_backup
- Lastly, create an
/usr/lib/firefox/firefoxexecutable by creating a new symbolic link from the
$ sudo ln -s /opt/firefox/firefox /snap/bin/firefox
Firefox should now be installed and usable.
To update your Firefox to the latest version, you just need to download the latest installation package and extract the package content:
$ wget -O ~/FirefoxSetup.tar.bz2 "https://download.mozilla.org/?product=firefox-latest&os=linux64" $ sudo tar xjf ~/FirefoxSetup.tar.bz2 -C /opt/
To uninstall Firefox, just remove the
/opt/firefox directory that we created, and revert your system back to using the default version of Firefox that was installed from the Ubuntu repository:
$ sudo rm -fr /opt/firefox $ sudo mv /snap/bin/firefox_backup /snap/bin/firefox
In this article, we learned several methods for installing, updating, and uninstalling Mozilla Firefox on Ubuntu 22.04 Jammy Jellyfish. Whether you want to use Ubuntu’s default package repository, Mozilla’s developer PPA, or Firefox’s official website, managing Firefox on your Ubuntu system is easy to do when following along with our step by step instructions.