Wine is an open-source compatibility layer that allows you to run  Windows applications on Unix-like operating systems such as Linux,  FreeBSD, and macOS. Wine stands  for Wine Is Not an Emulator. It is an interface that translates Windows  system calls into equivalent POSIX calls used by Linux and other  Unix-based operating systems.

Wine isn’t always the best option to  run Windows programs on Linux. Not all Windows applications will run in  Wine, even if they do, they may not behave in the same way that they  normally would. The Wine AppDB database contains a list of applications that have been tested and confirmed to work under Wine.

You can also use a virtualization tool like VirtualBox or VMware, but they require more system resources and a Windows installation.

This  tutorial explains how to install Wine on Ubuntu 18.04. We will show you  how to install the distro stable version 3.0 and the latest version of  Wine 4.0. The same instructions apply for Ubuntu 16.04 and any  Ubuntu-based distribution, including Linux Mint and Elementary OS.


To be able to install new packages on your Ubuntu system, you must be logged in as a user with sudo privileges.

Installing Wine 3.0 on Ubuntu

The Wine packages are included in the default Ubuntu repositories contain and can be easily installed with the apt package manager. This is the easiest way to install Wine on Ubuntu.  However the version included in the repositories may lag behind the  latest version of Wine.

Start by updating the packages list:

sudo apt update

Next, install Wine by typing the following command:

sudo apt install wine64

Once the installation is complete use the wine --version command to print the Wine version:

wine --version

At the time of writing this article, the current version of Wine available in the Ubuntu 18.04 repositories is 3.0.

wine-3.0 (Ubuntu 3.0-1ubuntu1)

Installing Wine 4.0 on Ubuntu

In this section, we will provide a step by step instructions about how to install Wine version 4.0 on Ubuntu 18.04.

First, import the GPG key of the WineHQ repository to your system using the following wget commands:

wget -qO- | sudo apt-key add -

Add the WineHQ repository by running the following commands:

sudo apt install software-properties-common

Install Wine 4.0 package by typing:

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

Verify the Wine installation by typing:

wine --version

The output should look something like this:


Configuring Wine

To configure Wine run the winecfg command in your terminal which will install Mono and Gecko and set up the Wine environment:


A dialog will appear asking whether you want to install mono.

Click on the “Install” button, and  the installation will start. Once done a new dialog will appear  prompting you to install Gecko. Again click on the “Install” button.

In the Wine configuration dialog,  you can configure various Wine settings. The default settings should be  fine in most cases. When finished, close the dialog box.

Installing Notepad++ on Ubuntu

Now that Wine is installed and configured, we will explain how to install Windows applications on your Ubuntu.

In this tutorial, we will install Notepad++, which is is one of the most popular text editors among Windows users. Launch your browser and download the Notepad++ installation file from the Notepad++ download page.

Once the download is complete start the installation by right-clicking on the .exe file and selecting “Open With Wine Windows Program Loader”.

The installation wizard will  start, select the language and install Notepad++ in the same way as you  would install any application on your Windows computer.

Windows applications are installed in the ~/.wine/drive_c/ directory.

To start the Notepad++ editor navigate to the ~/.wine/drive_c/Program Files (x86)/Notepad++ directory.

And double click on the notepad++.exe file.


You  have successfully installed and configured Wine on your Ubuntu 18.04  desktop. We have also shown you how to install and start Windows  applications under Wine.

If you hit a problem or have feedback, leave a comment below.