How to Install Latest Wine in Ubuntu Linux

Wine is a nifty utility that allows users to run Windows applications and games inside a Linux environment. Wine 7.0 is finally out, and it ships with an array of numerous improvements and a total of 40 bug fixes.

Some of the key areas that have witnessed great changes include:

  • Text console redesign
  • Vulkan support enhancements
  • Text and fonts
  • Kernel objects & functions
  • An array of core modules in PE format.
  • New WoW64 architecture.
  • Improved theming support, with a collection of themes for a more modern look.

For a more comprehensive list of the numerous changes that have been made, check out Wine’s announcement.

Let’s shift gears and focus on how to install Wine 7.0 on Ubuntu Linux.

Step 1: Enable 32-bit Architecture

The first course of action is to enable the 32-bit architecture using the dpkg command as follows:

$ sudo dpkg --add-architecture i386
Enable 32-bit Architecture
Enable 32-bit Architecture

Step 2: Add Wine Repository Key

Once the 32-bit architecture is added, proceed and add the Wine repository key using the wget command as shown.

$ sudo wget -nc -O /usr/share/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
Add Wine Key in Ubuntu
Add Wine Key in Ubuntu

You should get output on the terminal as seen from the screenshot above.

Step 3: Enable Wine Repository

Upon adding the repository key, the next step will be to enable the Wine repository. To add the repository, invoke the command shown:

For this version: Use this command:
Ubuntu 22.04 sudo wget -nc -P /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/jammy/winehq-jammy.sources
Ubuntu 21.10 sudo wget -nc -P /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/impish/winehq-impish.sources
Ubuntu 20.04
Linux Mint 20.x
sudo wget -nc -P /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/focal/winehq-focal.sources
Ubuntu 18.04
Linux Mint 19.x
sudo wget -nc -P /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/bionic/winehq-bionic.sources

Then update the system package lists as shown.

$ sudo apt update
Update System
Update System

Step 4: Install Wine 7.0 in Ubuntu

All that is left at this stage is to install Wine 7.0 on Ubuntu using the APT package manager as follows.

For this version: Use this command:
Stable branch sudo apt install --install-recommends winehq-stable
Development branch sudo apt install --install-recommends winehq-devel
Staging branch sudo apt install --install-recommends winehq-staging

This will install an array of packages, libraries, and drivers.

Install Wine in Ubuntu 20.04
Install Wine in Ubuntu 20.04

Once the installation is complete, verify the wine version as shown.

$ wine --version

wine-7.0

Step 5: Using Wine to Run Windows Programs in Ubuntu

To demonstrate how you can use Wine to run a Windows program, we downloaded Rufus executable file (.exe) from the Rufus official Site.

To run the file, run the command:

$ wine rufus-3.13.exe
Run Windows Program in Ubuntu
Run Windows Program in Ubuntu

Wine will start by creating a Wine config file in the home directory, in this case, ~/.wine as shown.

Wine Configuration
Wine Configuration

When prompted to install the wine-mono-package which is required by .NET applications, click the ‘Install’ button.

Wine Mono Installer
Wine Mono Installer

The download will soon start

Downloading Wine Mono Installer
Downloading Wine Mono Installer

Additionally, install the Gecko package which is required by applications embedding HTML.

Wine Gecko Installer
Wine Gecko Installer

Select whether you want to check for application updates from time to time.

Rufus Update Policy
Rufus Update Policy

Finally, the Rufus UI will be displayed as shown.

Rufus Programe Running on Ubuntu
Rufus Program Running on Ubuntu

We have successfully installed Wine on Ubuntu and gave you a preview of how you can execute Windows applications in .exe a format which normally wouldn’t run in a Linux environment.

Any thoughts or feedback on this guide? Do let us know.

If you read this far, tweet to the author to show them you care. Tweet a thanks
James Kiarie
This is James, a certified Linux administrator and a tech enthusiast who loves keeping in touch with emerging trends in the tech world. When I'm not running commands on the terminal, I'm taking listening to some cool music. taking a casual stroll or watching a nice movie.

Each tutorial at TecMint is created by a team of experienced Linux system administrators so that it meets our high-quality standards.

Join the TecMint Weekly Newsletter (More Than 156,129 Linux Enthusiasts Have Subscribed)
Was this article helpful? Please add a comment or buy me a coffee to show your appreciation.

12 thoughts on “How to Install Latest Wine in Ubuntu Linux”

  1. Any suggestion on how to install iTunes on Ubuntu 20.04 using Wine / Winetricks? I have tried many different ways to do this but it simply doesn’t work. Any help would be appreciated.

    Reply
    • $ sudo apt install --install-recommends winehq-stable
      
      Reading package lists... Done
      Building dependency tree... Done
      Reading state information... Done
      E: Unable to locate package winehq-stable
      nothing seems to work on mint 21.1 I can honestly say I feel like giving up on Linux.
      
      Reply
  2. In winehq-jammy.sources is a reference to another location

    Signed-By: /etc/apt/keyrings/winehq-archive.key

    Saving the key under /usr/share/keyrings/ will not work.

    Reply
  3. Hi, sorry for bothering you.

    Is there a way to force the wine to install (or reinstall) mono and ie8?

    I may have done something nasty to my Debian buster since I spent a few days in trying to install whatever versions of wine and winehq. The aim is to have a software named PublisherRocket.exe working.

    So I tried and deleted and purged and reinstalled and probably made such damage that… I can not have windows asking to install mono. Even if I delete the .wine directory, when I digit
    wine PublisherRocket.exe

    for the first time, the program does not work properly and wine does not ask for mono installation.

    Any hint on how to clean the system, and what to take care of, is highly appreciated.

    Thank you.

    Reply
  4. For adding the key, this worked for me:

    curl https://dl.winehq.org/wine-builds/winehq.key | gpg --dearmor | sudo tee /usr/share/keyrings/winehq-archive-keyring.gpg

    Reply
  5. Hi, I’m using Ubuntu and when I use this command you listed above.

    $ wget -qO - https://dl.winehq.org/wine-builds/winehq.key | sudo apt-key add -
    

    I get in the terminal

    Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)).
    OK

    Reply
  6. $ sudo apt --install-recommends winehq-stable
    

    Needs to be:

    $ sudo apt install --install-recommends winehq-stable
    

    Like in the picture below it.

    Reply

Got something to say? Join the discussion.

Thank you for taking the time to share your thoughts with us. We appreciate your decision to leave a comment and value your contribution to the discussion. It's important to note that we moderate all comments in accordance with our comment policy to ensure a respectful and constructive conversation.

Rest assured that your email address will remain private and will not be published or shared with anyone. We prioritize the privacy and security of our users.