We all have our preferences when it comes to the application we want to use for opening and working with a certain file type. For example, whenever I start using a new version of an operating system, I install and switch to the VLC media player for playing music and videos. In Debian, you can change your default applications both through the command line and the graphical user interface through the simple steps described in this tutorial. We have performed the commands and procedure described in this tutorial on the latest Debian 10 Buster system.

Change Debian default apps through the Command Line

When you access any application through the command line by a generic name, such as ‘editor’, it looks for the default application set in the system and points to the exact default application and opens it. For example when I enter the following command:

$ /usr/bin/editor

It opens the Nano editor on my system as it is the default text editor for Debian 10.

You can open the Terminal through the Application Launcher search as follows:

Debian Terminal

The Application Launcher can be accessed using the Super/Windows key through your keyboard.

If you want to change the default editor or any other program for that matter, you can use the update-alternatives utility for this purpose.


$ sudo update-alternatives –config [applicationname]

Example: Changing the default text editor

In this example I will change my default Nano editor to another preferable alternative through the following command:

$ sudo update-alternatives --config editor

This command will give me an entire list of alternatives for the text editor along with the one with auto mode status as follows:

Default Editor

By entering a selection number associated with my choice and then pressing Enter, I can switch to a new default text editor that will be used to open my text files next time by default.


If you use this command to look up alternatives but none exists, you will get the following message. You will then require downloading an alternative and then switching to it.

Update alternatives

Searching for alternatives all at once:

The following command will list, and let you choose from, an available list of alternatives for all your default applications.

$ sudo update-alternatives --all

The following output is displayed for my system, representing that there are alternatives available for many applications.

Update or change all default applications

By specifying a selection number and hitting Enter, I can change the default choice of application for my Debian. In order to keep the same choice for an application, simply press Enter without entering a choice.

Change Debian default applications through the GUI

A more user-friendly alternative to changing your default applications is through Debian’s graphical user interface. We will represent the following two ways to do so:

  • Through the Settings utility
  • By specifying default application for opening a certain file

Through the Settings Utility

Click the downward arrow located at the top right corner of your Debian desktop and then click the settings icon located at the bottom left corner:

Settings utility


Type Settings in the Debian Application Launcher search as follows:


The Settings utility will open displaying the Wi-Fi tab as default.

Click the Details tab and then the Default Applications tab.

The following view will list all the default applications of your system.

Default Applications

In order to choose a different application than the default one, click the downward arrow and make a new selection against a category as follows:

Change default app

In this image, I have selected Shotwell Viewer to open my photos instead of the default Image Viewer application.

Changing Default Application for Removable Media

Through the Devices tab in System Settings, select the Removable Media tab. The list of removable media and the default program to open the media will be displayed.

In order to change the default application, click the down-arrow beside the Other Application drop-down and select the application from the Select Application dialog as follows:

Select applications

You newly selected application will now be used for opening the removable media from then on.

Changing Default Application for Opening a Certain File Type

By setting the default application for opening a certain file, you can select the default application for opening all files of the same type. Here is an example:

Example: Setting all .png files to be opened in Shotwell Viewer

Through the file viewer, right-click a file with the .png extension and then select Properties as follows:

File properties

The Properties window will open.

Click on the “Open With” tab and select Shotwell Viewer (or any other preferable applications) and then click Reset.

Choose app to open file type with

Your newly selected application will not only open this .png file in the future but also all other files with .png extension.

In this tutorial, you have learned several ways to change the default application used to open a file on your Debian system. You can use both the command line or the two ways described in this tutorial for the GUI to select new applications that will be used to open your files.

How to Change Debian’s Default Applications

Karim Buzdar

About the Author: Karim Buzdar holds a degree in telecommunication engineering and holds several sysadmin certifications. As an IT engineer and technical author, he writes for various web sites. He blogs at LinuxWays.