How to Install and Use Wine on Ubuntu 22.04

Choose a different version or distribution

Introduction

Before we begin talking about how to install Wine on Ubuntu 22.04. Let’s briefly understand – What is Wine?

Wine Is Not an Emulator (Wine) is a free compatibility layer for Unix-like systems like Linux and macOS. Unlike its name suggests, it doesn't emulate Windows but translates Windows application binaries to interact with the underlying OS.

With Wine, you can run Windows software on your preferred system without needing a Windows license or virtual machine. It's continuously updated, supports a wide range of applications, and offers compatibility across platforms. Discover the power of Wine for seamless integration of Windows apps on Linux and macOS.

In this tutorial, you will install Wine on Ubuntu 22.04.

Advantages of Wine

  1. Compatibility: Wine enables running Windows applications on Linux and macOS systems, expanding software compatibility.
  2. Cost-effective: Eliminates the need for a Windows license or virtual machine, saving money.
  3. Seamless Integration: Windows software runs smoothly on non-Windows systems, providing a seamless user experience.
  4. Ongoing Development: Regular updates and improvements ensure enhanced compatibility and performance.
  5. Broad Application Support: Wine supports a vast number of applications and games, offering versatility for users.

Prerequisites to Install Wine on Ubuntu 22.04

Please ensure that you are logged in as a user with sudo privileges in order to install the new packages on your Ubuntu system.

Installing Wine 6.0.3 on Ubuntu

1) The apt package manager makes it incredibly simple to install the Wine packages, available in the regular Ubuntu repository. This is the most convenient method for installing Wine on Ubuntu. Versions in the repositories might not be fully up-to-date with the most recent Wine version.

The first step is to enable multiarch, which permits the installation of both 64-bit and 32-bit packages on the system.

sudo dpkg --add-architecture i386
sudo apt update

2) Install Wine using the following command:

sudo apt install wine64 wine32

3) Check the version after the installation is complete with the following command!

wine --version

4) In this case, the current Wine version available on Ubuntu 22.04 is 6.0.3.

Output

wine-6.0.3 (Ubuntu 6.0.3~repack-1)

Now that Wine 6.0 has been installed on your computer, you can start using it.

Installing Wine 8.0 on Ubuntu

1) Here, we'll guide you through the process of installing Wine 8.0 on Ubuntu 22.04.

First, update your package list and enable a 32-bit architecture if you are using a 64-bit Ubuntu system.

sudo dpkg --add-architecture i386
sudo apt update

2) Next, import the GPG key from the WineHQ repository. After that, run the following command:

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

3) The WineHQ repository has now been added to your system:

sudo apt install software-properties-common
sudo apt-add-repository 'deb http://dl.winehq.org/wine-builds/ubuntu/ bionic main'

4) After that, install Wine by executing the following command:

sudo apt-get install --install-recommends winehq-stable

5) Once the installation is complete, use the following command to check the Wine version:

wine --version

You will get an output like the one below:

Output

wine-8.0

Wine 8.0 has been successfully installed and is ready for use.

Configuring the Wine

1) You must execute the winecfg command, which will install Mono and Gecko, to configure the Wine environment.

winecfg

2) If you choose to install the wine-mono package, a dialogue box will appear.

3) Press the Install button once again to launch the installation. Once finished, a new dialogue box will pop up requesting you to install Gecko. Click the Install button again.

4) A prompt to configure wine settings will appear now. In most cases, the default options are adequate. Close the dialogue box after finishing the configuration.

Installing Notepad++ on Ubuntu using Wine

We will now use Wine to install Notepad++, a Windows application, on Ubuntu in order to better understand how Wine functions.

1) One of the most popular text editors among Windows users is Notepad++. Open your browser and download the installation file for Notepad++.

2) Right-click on the .exe file to begin the installation after downloading it. Next, select Open With the Wine Windows Program Loader.

3) The installation wizard will then launch, prompting you to choose a language and carry out the standard Windows installation procedures.

4) Windows applications are installed in the ~/.wine/drive c/ directory.

5) Go to ~/.wine/drive c/Program Files (x86)/Notepad++ directory and double-click on notepad++.exe file.

FAQs on how to Install Wine 6.0 on Ubuntu 22.04

Which programs work well with Wine?

Numerous software programs function effectively with Wine. In general, Wine runs older or simpler programs without any issues but the most recent iterations of complicated apps or games do not function adequately.

Is it possible to install drivers for your hardware using Wine?

No, your hardware should be functional on your operating system. Technically speaking, Wine, like many other programs, runs in user mode rather than kernel mode.

Is there any alternative to Wine for running Windows applications on Ubuntu 22.04?

Another option is PlayOnLinux, which simplifies the installation and management of Windows applications on Ubuntu. However, Wine is the most widely used and supported compatibility layer.

Does Wine have a graphical interface on Ubuntu 22.04?

Wine itself does not have a graphical interface, but it integrates with your Ubuntu desktop environment. Windows applications will run within their own windows, just like native Linux programs.

Can I use Wine to run Windows games on Ubuntu 22.04?

Yes, Wine supports various Windows games on Ubuntu. However, not all games may work flawlessly. Refer to the Wine AppDB for compatibility information and specific configurations.

How do I run Windows applications using Wine on Ubuntu 22.04?

Right-click on the Windows executable file and select "Open With Wine" or use the terminal command wine /path/to/application.exe to launch Windows applications through Wine.

Can I uninstall Wine from Ubuntu 22.04 if needed?

Yes, you can uninstall Wine by running the command sudo apt remove wine in the terminal. This will remove Wine and its associated packages from your system.

Conclusion

Hope this detailed tutorial helped you install Wine on Ubuntu 22.04.

If you have any queries or doubts, please leave them in the comment below. We'll be happy to address them.