How To Install a Deb File by dpkg or by APT on Debian

In this guide, you will learn to Install a Deb File by dpkg or by APT on Debian distros. A deb file is a software package file for Debian and Ubuntu. You can follow the steps below to see how to install a deb file on Debian distros in all versions.

What is a Deb File Used For?

The deb file is used for installation packages that include software developed for computers that run on the Linux operating system using the Debian package management application.

What is the difference between apt and dpkg?

APT is a front-end to dpkg that is more user-friendly. dpkg handles individual package activities, APT handles package relationships, as well as the sourcing and administration of higher-level versioning choices.

How To Install a Deb File by dpkg or by APT on Debian?

To complete this guide, you must have access to your server as a non-root user with sudo privileges. For this purpose, you can visit the Debian Initial Guides on the Orcacore website.

Then, follow the steps below.

Step 1 – Install Deb Files with dpkg on Debian

The dpkg is already installed by default in all Debian-based systems. You can use its option “-i” to install any deb files. The syntax is shown below:

sudo dpkg -i /path/package_name.deb

However, dpkg may give you a dependency error while installing the package.

dpkg: error processing package

If you get this error, then run the following command to install the pending dependencies:

sudo apt install -f

Then, install your deb package again.

Step 2 – Install Deb Files with APT on Debian

At this point, you can easily install any deb files with Apt on Debian.

To install deb files with APT, you can use one of the following commands:

# sudo apt install ./package_name.deb
# sudo apt install /path/package_name.deb

Step 3 – Install Deb Files with GDEBI on Debian

Also, there is another way to install a deb file. GDEBI is a package installer to install Debian executable packages on the Debian-based distribution of Linux. 

The Gdebi package manager is not installed by default in Debian. To install it, run the command below:

sudo apt install gdebi -y

When your installation is completed, you can use it to install any local deb file.

sudo gdebi /path/package_name.deb

The above command will install the deb file for you automatically.

That’s it, you are done.


At this point, you have learned to Install a Deb File by dpkg or by APT on Debian distros. Also, you can use another package manager named Gdebi to install the deb packages on your Debian distros.

Hope you enjoy it. You may be interested in these articles:

Install Gnome Desktop Environment on Debian 12

How To Install MySQL on Debian 12 Bookworm


Please enter your comment!
Please enter your name here
Captcha verification failed!
CAPTCHA user score failed. Please contact us!
Latest Articles


Most Popular