How To

How To Install Wine on Ubuntu 26.04 / 24.04 / 22.04

Wine is a compatibility layer that lets you run Windows applications on Linux without needing a virtual machine or dual-boot setup. It translates Windows API calls into POSIX calls on the fly, giving you near-native performance for most Windows software. This guide installs Wine on Ubuntu from the official WineHQ repository, and covers the Linux Mint and Debian variants of the same steps where they differ. It was run through in August 2026 against WineHQ stable 11.0, and the repository layout for Ubuntu 26.04 has changed enough that instructions written for 24.04 will fail on it.

Original content from computingforgeeks.com - post 7555

Wine has matured significantly over the years and now supports a wide range of Windows applications, from productivity tools and games to legacy enterprise software. Whether you need to run a specific Windows-only application or you are migrating from Windows to Linux, Wine is the go-to solution.

Prerequisites

Before you begin, make sure you have the following in place:

  • A running installation of Ubuntu 26.04, 24.04 or 22.04. The steps are the same on Linux Mint and on Debian, with a different repository file in each case
  • A user account with sudo privileges
  • A stable internet connection
  • Basic familiarity with the Linux terminal

Ubuntu’s own Wine package or WineHQ

There is nothing to download from a web page here. Wine is not an installer you fetch and double click, so every search for a Wine download on Ubuntu arrives at the same two options: the wine package in Ubuntu’s own archive, or the WineHQ repository that the rest of this guide sets up. Ask APT what your release offers before you decide:

apt-cache policy wine winetricks

The candidate version is what matters. Across the three supported releases it looks like this:

Ubuntu 26.04 LTS (resolute)
  wine        10.0~repack-12ubuntu1
  winetricks  20250102-1build1

Ubuntu 24.04.4 LTS (noble)
  wine        9.0~repack-4build3
  winetricks  20240105-2

Ubuntu 22.04.5 LTS (jammy)
  wine        6.0.3~repack-1
  winetricks  0.0+20210206-2

Ubuntu freezes whatever Wine was current when the release was cut, so the gap widens the older your Ubuntu is. On the newest release you are one Wine release behind; on the oldest you are running a build from early 2021, which predates several years of Windows API work and a full rewrite of how Wine handles 32-bit code. WineHQ carries the current stable release for all three.

If you need one undemanding Windows program open and you do not care which Wine opens it, the archive package is a single command and you can stop reading here. It is a big install either way, 331 packages on the newest release:

sudo apt install wine winetricks

For anything you actually depend on, take the WineHQ route below. Newer Wine fixes bugs in the applications you are trying to run, and when you report a problem upstream the first thing you will be asked is whether it reproduces on current stable.

Step 1: Enable 32-bit Architecture

On Ubuntu 24.04 and 22.04, WineHQ splits Wine into wine-stable-amd64 and wine-stable-i386, so APT needs the i386 architecture enabled before it can resolve the install. Add it first:

sudo dpkg --add-architecture i386

Verify that the i386 architecture has been added:

Skip this step on Ubuntu 26.04. WineHQ publishes an amd64-only repository for the resolute suite, with no i386 package index at all, because Wine’s new WoW64 mode runs 32-bit Windows programs inside a 64-bit prefix without any 32-bit host libraries. Enabling i386 there just makes APT fetch an index that does not exist.

dpkg --print-foreign-architectures

i386 should appear in the output. If it does, carry on.

Step 2: Add the WineHQ Official Repository

The Wine packages in the default Ubuntu and Debian archives lag well behind upstream. The official WineHQ repository carries the current stable release instead.

Start by downloading and installing the WineHQ repository signing key:

sudo mkdir -pm755 /etc/apt/keyrings
sudo wget -O /etc/apt/keyrings/winehq-archive.asc https://dl.winehq.org/wine-builds/winehq.key

WineHQ’s own documentation saves that file as winehq-archive.key. That still works on Ubuntu 24.04 and 22.04, but it fails on Ubuntu 26.04, where APT 3.2 refuses an ASCII-armored key stored under a .key name and reports the repository as unsigned. Debian 13 is not affected, because the APT 3.0 it ships still accepts it:

The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 76F1A20FF987672F
E: The repository 'https://dl.winehq.org/wine-builds/ubuntu resolute InRelease' is not signed.

The file contents are identical either way. Naming it .asc is what makes APT read it as armored. Dearmoring it to .gpg with gpg --dearmor works too, as long as the Signed-By line in the sources file points at whichever name you used.

For Ubuntu 26.04 (Resolute Raccoon):

sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/resolute/winehq-resolute.sources

For Ubuntu 24.04 (Noble Numbat):

sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/noble/winehq-noble.sources

For Linux Mint 22 (based on Ubuntu 24.04):

sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/noble/winehq-noble.sources

For Debian 13 (Trixie):

sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/debian/dists/trixie/winehq-trixie.sources

Confirm the repository file was downloaded successfully:

ls -l /etc/apt/sources.list.d/winehq-*.sources

The sources file should be listed. Update the package index next:

sudo apt update

Make sure the update completes without errors. If you see GPG key warnings, double-check that the key was downloaded correctly in the earlier step.

Step 3: Install Wine

WineHQ offers several branches you can choose from. The two most commonly used are:

  • wine-stable – Recommended for most users. Thoroughly tested releases.
  • wine-staging – Contains experimental patches and newer features. Good if you need cutting-edge support.

To install the stable branch:

sudo apt install --install-recommends winehq-stable

To install the staging branch instead:

sudo apt install --install-recommends winehq-staging

The installation will pull in a significant number of dependencies (both 64-bit and 32-bit libraries). This is normal. Accept the prompts and let the process complete.

Step 4: Verify the Installation

Once the installation finishes, confirm that Wine is properly installed by checking its version:

wine --version

You should see output similar to:

wine-11.0

If the version number matches the current stable line, the installation worked. There is no wine64 command to check any more: that loader was removed and a single wine binary now selects 32-bit or 64-bit from the executable you give it. You can also check the Wine binary path:

which wine

Expected output: /usr/bin/wine or /opt/wine-stable/bin/wine depending on your configuration.

Step 5: Configure Wine with winecfg

The first time you run Wine, it needs to set up a default Wine prefix (a virtual Windows environment). Launch the Wine configuration tool:

winecfg

On the first run, Wine will prompt you to install wine-mono (a replacement for .NET Framework) and wine-gecko (a replacement for Internet Explorer). Accept both of these because they are needed by many Windows applications.

Once the configuration window opens, you can adjust the following settings:

  • Windows Version – Set the Windows version Wine should emulate. Windows 10 is a solid default for most applications.
  • Drives – Map Linux directories to Windows drive letters.
  • Graphics – Adjust screen resolution and allow the window manager to control Wine windows.
  • Audio – Select your audio driver (PulseAudio or ALSA).

The default Wine prefix is created at ~/.wine. This directory contains the virtual C: drive and Windows registry files.

Step 6: Install Winetricks for Common Windows Components

Winetricks is a helper script that simplifies installing common Windows runtime libraries and components that many applications depend on. Install it with:

sudo apt install winetricks

Verify the installation:

winetricks --version

With winetricks installed, you can now add essential Windows components. Here are some of the most commonly needed ones:

Install .NET Framework:

winetricks dotnet48

Install Visual C++ runtime libraries:

winetricks vcrun2019

Install common Windows fonts:

winetricks corefonts

Install DirectX runtime:

winetricks d3dx9

You can also launch the winetricks GUI to browse and select components interactively:

winetricks --gui

Step 7: Run a Windows Application

Running a Windows executable with Wine is straightforward. If you have downloaded a Windows .exe file, simply run:

wine /path/to/application.exe

For example, to run a downloaded installer:

wine ~/Downloads/setup.exe

Wine will handle the execution and display the Windows application using your Linux display server. Most installers will place files under the Wine prefix’s virtual C: drive at ~/.wine/drive_c/.

After installation, you can run the application from its installed location:

wine ~/.wine/drive_c/Program\ Files/ApplicationName/app.exe

To check application compatibility before installing, visit the Wine Application Database (AppDB) where users report how well specific software runs under Wine.

Step 8: Configure Display and Audio Settings

If you run into display or audio issues, Wine provides several ways to fine-tune these settings.

Display Configuration

Open the Wine registry editor to adjust display settings:

wine regedit

Navigate to HKEY_CURRENT_USER\Software\Wine\X11 Driver to modify DPI and screen resolution settings. You can also set the virtual desktop resolution through winecfg under the Graphics tab. This is useful for applications that try to change your screen resolution.

To enable a virtual desktop (prevents applications from changing your actual resolution):

wine explorer /desktop=AppName,1920x1080 /path/to/application.exe

Audio Configuration

Wine supports PulseAudio, PipeWire, and ALSA for audio output. Most modern Ubuntu and Linux Mint installations use PipeWire (with PulseAudio compatibility), which Wine handles well out of the box.

If you experience audio issues, open winecfg, go to the Audio tab, and test the audio output. You can also force a specific audio driver:

winetricks sound=pulse

Step 9: Use Wine Prefixes to Isolate Applications

Wine prefixes are one of the most powerful features for managing multiple Windows applications. Each prefix is a self-contained Windows environment with its own registry, installed components, and configuration. This prevents applications from conflicting with each other.

To create and use a custom Wine prefix, set the WINEPREFIX environment variable before running Wine commands:

export WINEPREFIX=~/wine-prefixes/myapp
winecfg

This creates a new, isolated Wine environment at ~/wine-prefixes/myapp. You can then install and run your application within this prefix:

WINEPREFIX=~/wine-prefixes/myapp wine ~/Downloads/setup.exe

You can also create a 32-bit only prefix, which is required by some older applications:

WINEPREFIX=~/wine-prefixes/myapp32 WINEARCH=win32 winecfg

Install specific components into a prefix using winetricks:

WINEPREFIX=~/wine-prefixes/myapp winetricks vcrun2019 dotnet48 corefonts

This approach keeps your default ~/.wine prefix clean and makes it easy to remove an application completely by simply deleting its prefix directory.

Troubleshooting Common Issues

Here are solutions to the problems you are most likely to hit.

“wine: could not load kernel32.dll” Error

This usually means the Wine prefix is corrupted. Delete the prefix and recreate it:

rm -rf ~/.wine
winecfg

Missing 32-bit Libraries

If you see errors about missing i386 libraries on Ubuntu 24.04 or 22.04, make sure the 32-bit architecture was enabled and install the missing packages. On Ubuntu 26.04 this error means something else, because that repository has no i386 packages to miss:

sudo dpkg --add-architecture i386
sudo apt update
sudo apt install libgl1:i386 libvulkan1:i386

Application Crashes on Launch

Try running the application from a terminal to see error output:

WINEDEBUG=+err wine /path/to/application.exe 2>&1 | tee wine-debug.log

Check the log file for clues. Common fixes include installing missing runtime components with winetricks or switching to a different Windows version in winecfg.

Font Rendering Issues

If fonts look garbled or missing, install the core Windows fonts:

winetricks corefonts allfonts

Graphics or Rendering Problems

For applications with graphical glitches, try overriding the renderer:

winetricks renderer=gl
winetricks renderer=vulkan

Make sure your GPU drivers are up to date. NVIDIA users want the proprietary driver; on AMD and Intel the bundled Mesa drivers are fine.

Slow Performance

If applications run slowly, consider using the staging branch which includes performance patches. You can also try enabling esync or fsync:

WINEESYNC=1 wine /path/to/application.exe

Make sure your system’s open file limit is high enough for esync:

ulimit -Hn

If the value is below 524288, add the following to /etc/security/limits.conf:

your_username hard nofile 524288
your_username soft nofile 524288

Removing Wine Completely

If you need to start fresh or remove Wine entirely:

sudo apt remove --purge winehq-stable
sudo apt autoremove
rm -rf ~/.wine
rm -rf ~/.local/share/applications/wine*

Conclusion

Wine is now installed and configured from the WineHQ repository, so it will track new stable releases through your normal updates. Using Wine prefixes and winetricks gives you full control over the Windows compatibility environment for each application you run. Check the Wine AppDB before installing any application to see compatibility reports and tips from other users.

Keep reading

Upgrade Ubuntu 24.04 to Ubuntu 26.04 LTS (Step by Step) Ubuntu Upgrade Ubuntu 24.04 to Ubuntu 26.04 LTS (Step by Step) Create Bootable Windows USB and Install Windows 11 Windows Create Bootable Windows USB and Install Windows 11 UFW Firewall Commands with Examples on Ubuntu 24.04 / 22.04 Security UFW Firewall Commands with Examples on Ubuntu 24.04 / 22.04 Install Arcane on Ubuntu 26.04 / 24.04: Complete Docker UI Guide Containers Install Arcane on Ubuntu 26.04 / 24.04: Complete Docker UI Guide Install NVIDIA Drivers and CUDA Toolkit on Ubuntu 26.04 / 24.04 Ubuntu Install NVIDIA Drivers and CUDA Toolkit on Ubuntu 26.04 / 24.04 Install and Configure DNS Server in Windows Server 2025 Windows Install and Configure DNS Server in Windows Server 2025

Leave a Comment

Press ESC to close