Wine is a software application designed to make Windows programs work on Linux. Wine acts as a compatibility layer, translating Windows system calls into Linux-friendly ones. This means you can install and run many popular Windows applications directly on Ubuntu.
In this write-up, we’ll demonstrate how to install, update, and remove Wine from Ubuntu using simple step-by-step instructions.
How to Install Wine on Ubuntu 24.04
Unlike traditional emulators, Wine does not slow down your system and is built to deliver better performance while bridging the gap between Linux and Windows software. However, Wine is not preinstalled and must be manually installed. You can download Wine and install it using Ubuntu’s default repository or WineHQ.

Try HostOnce’s Dedicated Servers for Ultimate Performance!
HostOnce gives you full control, powerful hardware, strong uptime, and top-level security. It’s a great choice for high-traffic websites and demanding applications.
Let’s start with the default Ubuntu Repository.
Method 1: Using the Default Repository
Installing Wine in Ubuntu is easy when you use the official apt repository. The official repository might not always install the most recent version of Wine. The official Ubuntu repository, however, guarantees the stable version of Wine.
Step 1: Check System Architecture
Wine has different applications for 64-bit and 32-bit architectures
lscpu
Step 2: Update System Repositories
This command will update your local repositories after detecting your CPU architecture:
sudo apt update && sudo apt upgrade
Step 3: Install Wine on Ubuntu
It’s now time to install Wine in Ubuntu after you have determined your CPU architecture. Install Wine if you have a CPU that is 64-bit:
sudo apt install wine64
If you have a CPU that is 32-bit CPU, then run the following command to install Wine:
| sudo apt install wine32 |
Step 4: Check Wine Version
Run the following command to verify that you have installed Wine correctly:
wine --version
Method 2: Using the WineHQ Repository
WineHQ’s repository is another way to install Wine. WineHQ contains the most recent Wine version, but it might not be stable. Install Wine using the WineHQ repository.
Step 1: Enable 32-bit Architecture
WineHQ can only be installed on a 32-bit system. Ubuntu stopped supporting 32-bit architecture in 2017. We can therefore assume that all Ubuntu systems are 64-bit.
Execute the following command to enable 32-bit architecture:
sudo dpkg --add-architecture i386
Step 2: Update System Repositories
Update the local repositories once the 32-bit architecture has been enabled. To update Ubuntu before installing any packages, use the following command:
sudo apt update
Step 3: Add the Wine Repository Keys
Add security keys to your system before installing Wine. This will allow you to communicate securely with the repository. Run the following command to add security keys to your system:
sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
Step 4: Add WineHQ Repository
Add the WineHQ repository to your system. This is where you can install Wine in Ubuntu. Run the following command to add the WineHQ repositories to your system:
sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/jammy/winehq-jammy.sources
Step 5: Update Packages List
Update the system package list to include the WineHQ repository once the repository has been added.
sudo apt update
Step 6: Install Wine on Ubuntu
Install Wine from the WineHQ repository. Run the following command to install the stable version of Wine from the WineHQ repositories:
sudo apt install --install-recommends winehq-stable
Users can install the latest version of WineHQ through the following command:
sudo apt install --install-recommends winehq-devel
Step 7: Verify Wine Installation
Verify Wine’s installation after installing it by running the following command:
wine --version
How to Update Wine on Ubuntu?
You can upgrade Wine to the latest version if you have already installed it on Ubuntu. Executing the following command on Ubuntu will upgrade Wine to its latest version:
sudo apt-get upgrade winehq-stable
How to Remove Wine from Ubuntu?
You can remove Wine if you have finished using it or if you want to remove it for another purpose. To do this, execute the following command.
sudo apt remove wine
This command will remove Wine but not its dependencies from Ubuntu:
You can also remove Wine’s dependencies using the following command:
sudo apt autoremove wine
Wine will also remove any other dependencies from other programs.
It is now recommended that you remove all folders associated with the Wine application. By executing these commands, you can remove the Wine folders one at a time.
rm -rf $HOME/.wine
rm -f $HOME/.config/menus/applications-merged/wine*
rm -rf $HOME/.local/share/applications/wine
rm -f /.local/share/desktop-directories/wine*
rm -f /.local/share/icons/????_*.xpm
After you have removed all folders, run the command given to remove all temporary files related to the Wine package.
sudo apt-get remove --purge ^wine
Execute the commands given one at a time to fix any errors.
sudo apt autoclean
Good to Know From domains to hosting, HostOnce has everything you need to launch your online project.
Conclusion
Wine can be installed on Ubuntu either from the official repository or the WineHQ repository. For the official repository, check your system architecture first, then install Wine64 for 64-bit systems or Wine32 for 32-bit systems. For WineHQ, enable 32-bit architecture, add its repository and keys, and install it using sudo apt install winehq-stable. In this article, we discussed both these methods with step-by-step instructions.
FAQs
How is the installation of Wine possible on Ubuntu 24.04?
First, enable 32-bit architecture using sudo dpkg --add-architecture i386. Add the WineHQ repository to your package list and then install Wine by using sudo install winehq-stable.
Do I need to configure Wine or install any additional dependencies after I Install Wine?
Wine can require additional fonts or libraries to function properly. Utilize winecfg for initializing the Wine environment. Also, for configuring such as the Windows version or graphics.
What Windows applications can I run with Wine?
Some applications might not run perfectly with Wine. They may have bugs or not work at all. Before installing, it's a good idea to check their compatibility in the Wine Application Database.
How can I remove Wine from Ubuntu?
To remove Wine, run sudo apt remove winehq followed by sudo apt autoremove to clean up unused packages. Also, delete the .wine folder in your home directory to remove leftover configuration files.