In this article, we want to teach you How To Install Wine on Debian 11.
Wine is not an Emulator but a compatibility layer capable of running Windows applications on several POSIX-compliant operating systems, such as Linux, macOS, & BSD. It will always be free software.
Approximately half of Wine’s source code is written by volunteers, with the remaining effort sponsored by commercial interests, especially CodeWeavers, which sells a supported version of Wine.
How To Install Wine on Debian 11
Before you start to install Wine, you need to log in to your server as a non-root user with sudo privileges. To do this, you can follow our article the Initial Server Setup with Debian 11.
Now follow the steps below to install WineHQ on Debian 11.
Install WineHQ on Debian 11
At this point, you need to identify your system is 32-bit or 64-bit with the command below:
If you notice the line CPU op-mode(s), this entry tells what you are running.
- 32-bit means you are running a 32-bit Linux OS
- 32-bit, 64-bit signifies that you are running a 64-bit OS
To use the latest up-to-date versions from Wine, you will need to use their repository to install or update.
First, you need to add the i386 architecture with the command below:
sudo dpkg --add-architecture i386
Then, you need to import the GPG key on Debian 11 with the command below:
sudo wget -qO- https://dl.winehq.org/wine-builds/winehq.key | sudo apt-key add -
If downloaded and imported successfully, you should get the output:
Next, you need to add the Wine repository on Debian 11 with the following command:
sudo apt install software-properties-common && sudo add-apt-repository 'deb https://dl.winehq.org/wine-builds/debian/ bullseye main'
Update your local package index:
sudo apt update
At this point, you can install Wine with the command below:
sudo apt install --install-recommends winehq-stable
Note: If you prefer to install the development branch instead, use the following:
sudo apt install --install-recommends winehq-devel
The WineHQ Development branch is the most recent version of Wine from the developers. It can often be unstable and should only be installed by developers and not the average user unless you want to live on the edge.
Now you can verify your Wine installation on Debian 11 by checking its version:
Uninstall WineHQ from Debian 11
If you don’t use Wine anymore you can easily remove it from your server.
To remove WineHQ stable, you can use the following command:
sudo apt autoremove --install-recommends winehq-stable --purge
If you use WineHQ development, to remove it you can use the command below:
sudo apt autoremove --install-recommends winehq-devel --purge
At this point, you learn to Install Wine on Debian 11.
Hope you enjoy using it.