Microsoft Edge is a Chromium-based web browser that offers a fast, secure, and feature-rich browsing experience. It includes advanced features like tracking prevention, integration with Microsoft services, and support for a wide range of extensions. For Ubuntu users, installing Microsoft Edge provides access to a browser that is optimized for performance and designed to work seamlessly across different devices.
To install Microsoft Edge on Ubuntu 24.04, 22.04, or 20.04, you can use the official Microsoft APT repository. This repository allows you to easily install and update the latest stable, beta, or dev builds of Edge. This guide will walk you through the installation process using the command-line terminal, ensuring you have the latest version of Microsoft Edge set up on your system.
Update Ubuntu Before Microsoft Edge Installation
Before installing Microsoft Edge, it’s crucial to update your system. This step ensures that all packages are current, minimizing potential conflicts during the Edge installation.
Execute the command below in your terminal to update your system:
sudo apt update && sudo apt upgrade
This command initiates two distinct actions. sudo apt update refreshes the list of available packages and their versions, but it doesn’t install or upgrade any packages. sudo apt upgrade, on the other hand, actually installs newer versions of the packages you have. By running these commands together, you ensure your system is fully up-to-date.
Install Essential Packages for Microsoft Edge
After updating your system, the next step is to install the necessary packages required for Microsoft Edge installation. These packages ensure a smooth setup process. Use the following command in your terminal to install them:
sudo apt install software-properties-common apt-transport-https curl ca-certificates -y
This command installs several key packages:
- software-properties-common: This package provides tools for managing the software sources in Ubuntu.
- apt-transport-https: It enables the Advanced Package Tool (APT) to use the ‘https’ protocol for secure communication.
- curl: This command-line tool supports data transfer with URLs, which is essential for fetching data from servers.
- ca-certificates: This package includes essential public key certificates for verifying SSL/TLS connections.
These packages facilitate the installation of Microsoft Edge and are fundamental for numerous other installations and operations on almost all Linux distributions.
Import Microsoft Edge APT Repository
To install Microsoft Edge on Ubuntu, it’s essential to import the Microsoft Edge repository first. This lets you download and install Microsoft Edge using Ubuntu’s package manager.
Begin by downloading the GPG key, which is necessary to verify the authenticity of the Microsoft Edge package. Execute this command in your terminal:
curl -fSsL https://packages.microsoft.com/keys/microsoft.asc | sudo gpg --dearmor | sudo tee /usr/share/keyrings/microsoft-edge.gpg > /dev/null
This command fetches the GPG key and securely stores it in the /usr/share/keyrings/ directory under the name microsoft-edge.gpg.
Next, integrate the Microsoft Edge repository into your system with this command:
echo 'deb [arch=amd64 signed-by=/usr/share/keyrings/microsoft-edge.gpg] https://packages.microsoft.com/repos/edge stable main' | sudo tee /etc/apt/sources.list.d/microsoft-edge.list
This command creates a new file named microsoft-edge.list in the /etc/apt/sources.list.d/ directory, effectively adding the Microsoft Edge repository.
Finally, update your system’s repository list to include the newly added Microsoft Edge repository:
sudo apt update
Running this command refreshes your repository list, making Microsoft Edge available for installation through the Ubuntu package manager.
Finalize Microsoft Edge Browser Installation
After adding the Microsoft Edge repository, you’re set to install the browser. Microsoft Edge offers stable, beta, and dev (nightly) versions.
Install the Stable Version of Microsoft Edge
For most users, the stable version is the recommended choice. To install it, use this command:
sudo apt install microsoft-edge-stable
This command installs the stable version of Microsoft Edge on your Ubuntu system. To confirm the version and build of Microsoft Edge, run:
microsoft-edge -version
Install Microsoft Edge Beta or Dev Versions
The Beta or Dev versions are available for users interested in the latest features. However, these versions are less stable and not recommended for daily use on primary devices or production servers.
Install Microsoft Edge Beta Version
To install the Beta version, use this command:
sudo apt install microsoft-edge-beta
Verify the installed Beta version with:
microsoft-edge-beta --version
Install Microsoft Edge Dev Version
To install the Dev (Nightly) version, which includes the newest features and updates, use:
sudo apt install microsoft-edge-dev
Confirm the installation of the Dev version with:
microsoft-edge-dev --version
Launch Microsoft Edge Browser
After installing Microsoft Edge on your Ubuntu system, you can open it in multiple ways via the terminal or graphical interface.
Launching Microsoft Edge Using the Terminal
To open the stable version of Microsoft Edge through the terminal, enter:
microsoft-edge
For the Beta version, use:
microsoft-edge-beta
And for the Dev (Nightly) version, the command is:
microsoft-edge-dev
Launching Microsoft Edge via the Graphical Interface
For users who prefer a graphical interface, launching Microsoft Edge is straightforward:
- Click on the Applications menu on your Ubuntu desktop.
- Type “Microsoft Edge” in the search bar.
- Click on the Microsoft Edge icon to open the browser.
Managing Microsoft Edge
Updating Microsoft Edge
Regularly updating Microsoft Edge is crucial for accessing new features and maintaining security. Perform these updates on Ubuntu with the following steps:
Update the System for Edge
First, check for updates using the APT update command:
sudo apt update
Then, apply any available updates with the upgrade option:
sudo apt upgrade
Update Specific Versions of Microsoft Edge
Use the appropriate command for your version to update only the Microsoft Edge package. For the stable version:
sudo apt upgrade microsoft-edge-stable
For updating the Beta or Dev versions of Microsoft Edge:
sudo apt upgrade microsoft-edge-beta
sudo apt upgrade microsoft-edge-dev
Removing Microsoft Edge
If you decide to uninstall Microsoft Edge from your Ubuntu system, follow these steps:
Remove Installed Versions of Microsoft Edge
Use the relevant command for the version installed:
Firstly, for the Microsoft Edge Stable version:
sudo apt remove microsoft-edge-stable
Secondly, Microsoft Edge Beta:
sudo apt remove microsoft-edge-beta
Lastly, Microsoft Edge Dev:
sudo apt remove microsoft-edge-stable-dev
Remove Repository and GPG Key
After uninstalling, remove the previously imported Microsoft Edge repository:
sudo rm /etc/apt/sources.list.d/microsoft-edge.list
Also, delete the imported GPG key:
sudo rm /usr/share/keyrings/microsoft-edge.gpg
These steps completely remove Microsoft Edge and its components from your Ubuntu system.
Managing Conflicting sources.list Files for Microsoft Edge
When installing different versions of Microsoft Edge on Ubuntu, each version may inadvertently create its own sources.list file in the /etc/apt/sources.list.d/ directory. These additional files often conflict with the correctly configured source list, potentially leading to update errors or ignored sources during apt update.
Identifying and Removing Redundant sources.list Files
The first step is to remove these unnecessary Microsoft Edge sources.list files. This action ensures that your system only refers to the correct and previously set up repository. Use the following command to safely remove these files:
sudo rm /etc/apt/sources.list.d/microsoft-edge*
This command targets explicitly and removes any sources.list files related to Microsoft, including those created by different Edge installations.
Re-Adding the Proper Microsoft Edge Repository
After cleaning up the redundant files, it’s crucial to re-establish the correct Microsoft Edge repository. This action will align your system with the setup outlined in this guide. Re-add the repository using this command:
echo 'deb [arch=amd64 signed-by=/usr/share/keyrings/microsoft-edge.gpg] https://packages.microsoft.com/repos/edge stable main' | sudo tee /etc/apt/sources.list.d/microsoft-edge.list
This command creates a new sources.list file specifically for Microsoft Edge, ensuring your system fetches updates from the correct, verified source.
Updating the APT Repository List
Finally, to apply these changes, update your APT repository list:
sudo apt update
This command refreshes your system’s package list, which is now correctly sourced from the re-added Microsoft Edge repository.
Conclusion
With Microsoft Edge installed on your Ubuntu system using the official APT repository, you can enjoy a secure and efficient browsing experience with access to the latest features and updates. The repository simplifies the installation process and ensures that your browser remains up-to-date with the latest stable, beta, or dev releases. Regularly check for updates through the repository to keep your browser optimized and secure, taking full advantage of the capabilities Microsoft Edge offers on Ubuntu.