During a Debian installation the setup asks which software groups should be installed: a desktop environment, an SSH server, a web server and so on. This selection comes from tasksel – and the program can also be run later, for instance to give a server a graphical interface after all.
Installing and running it
sudo apt install tasksel
sudo tasksel
The same selection menu as during installation appears. Use the space bar to select or deselect collections, and Tab and Enter to confirm. Careful: if you deselect a collection that is already installed, tasksel removes its packages.
Listing the available collections
tasksel --list-tasks
An i at the beginning of a line means “installed”, a u “not installed”. To see which packages belong to a collection:
tasksel --task-packages ssh-server
Installing without the menu
sudo tasksel install ssh-server
sudo tasksel install xfce-desktop
On Debian every collection has a metapackage of the same name with the prefix task-. That is handy for scripts and Ansible:
apt search '^task-'
sudo apt install task-xfce-desktop task-german
The task-german collection (or task-german-desktop), by the way, installs German translations and dictionaries; matching collections exist for many other languages.
On Ubuntu
tasksel works on Ubuntu as well but is hardly used there any more, since the server installer has its own selection options. The metapackages of the desktop flavours are more common:
sudo apt install ubuntu-desktop-minimal # GNOME, lean selection
sudo apt install kubuntu-desktop # KDE Plasma
sudo apt install xubuntu-desktop # Xfce
A desktop pulls in several hundred packages. On a server you should think carefully about whether a graphical interface is really necessary – SSH is usually enough for administration.
Originally published in 2012, completely revised in November 2026.