Home>Posts>How To, I/O HUB, Tech Explained>How To Enable Ubuntu Linux Bash in Windows 10

How To Enable Ubuntu Linux Bash in Windows 10

By ·Categories: How To, I/O HUB, Tech Explained·Published On: September 30th, 2020·4.8 min read·

Installing Ubuntu Linux Bash in Windows 10 is a powerful tool that enables users to access Linux commands and software without needing to setup a dual-boot system or installing and managing a Virtual Machine. As Microsoft continues to improve support for Windows System for Linux, or WSL, the process for enabling and installing the Ubuntu Bash shell becomes increasingly easy for the user, however it is still not strictly intuitive. Here’s what you need to do.

Step by Step Instructions to Install Ubuntu Linux Bash in Windows 10

Which Windows Subsystem for Linux (WSL) is right for you?

The first step to enabling Bash in Windows 10 is determining which version of the Windows Subsystem for Linux (WSL) is right for you. While they both provide seamless integration of Linux within Windows, WSL 1 and WSL 2 operate on different architectures and will be beneficial for different use cases. 

WSL 1 operates as a compatibility layer, allowing the user to run Linux binary executables on Windows 10. This layer translates Linux system calls into Windows system calls and then executes them natively within Windows. This architecture requires any updates to the Linux kernel to be implemented separately by the Windows team which adds additional time to the update process. The translation of commands also causes WSL 1 to suffer from poor I/O performance for tasks such as database management, Git operations, and package installation and updates. The key benefit of WSL 1 is the ability to access project files natively in the Windows file system. 

WSL 2, on the other hand, is a full Linux kernel operating within a managed Virtual Machine (VM). The kernel is updated during normal Windows updates and is built off the latest stable branch which can be found at kernel.org. The benefits of this architecture include full system call compatibility. This enables applications that were previously impossible to run on WLS 1 due to lack of support from the translation layer, such as Docker. Not requiring system call translation significantly speeds up multiple functions leading to a 2-5x speed increase for tasks such as ‘git clone’. A third benefit of this architecture is that Linux kernel updates are immediately available for use and do not need to be implemented in the WSL 1 translation layer then pushed to users. The WSL 2 managed VM environment, unlike a traditional VM, is designed to boot quickly, optimize resource usage, and require no direct user management.

For most users it is recommended to use WSL 2 due to the increased application compatibility, faster IO speeds, and quicker kernel update cycles. WSL 1 is recommended only when your project files must be stored in the Windows 10 file system or your project files will require cross-compilation using Windows and Linux tools.  

Check your Windows 10 Version

Make sure you are running a supported version of Windows 10

For WSL 1 you need the Windows 10 Fall Creators, Version 1709 or higher for WSL 2 you will need to be updated to the May 2020 Update, Version 2004 or higher. Check out this information from Microsoft for more information – What’s the difference between WSL 1 and 2?

To check your version of Windows 10 

  1. Select Start and then select Settings 
  2. In  Settings, Select System > About
  3. Scroll down to Windows Specifications

Windows specification box used to determine version of Windows 10

Enabling Windows Subsystem for Linux

Next, you’ll need to enable the Windows Subsystem for Linux. To do this you will need to open PowerShell as an Administrator and run the command corresponding to your desired WSL version.

To enable WSL 1 run the command:

  • dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart

For WSL 1 you can now skip to the “Install Ubuntu for Windows 10” step

To enable WSL 2 run the below commands:

  • dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
  • dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Once your command has successfully completed, restart Windows 10.

WSL 2 Powershell screen shot

Install Linux Kernel update Package

Download the WSL Linux kernel package update for x64 systems

Run the .msi installer downloaded

Update Setup Wizard complete message for WSL Update

Set WSL 2 as the default version

In powershell, run the command

  • wsl –set-default-version 2

Screenshot of powershell window while setting WSL 2 as default version

Install Ubuntu for Windows 10

Ubuntu is available for free from inside the Microsoft Store on Windows 10

  1. In the start menu type “Microsoft Store” and hit enter. Or click here for the web browser version of the store
  2. Search “Ubuntu and select the top result, ‘Ubuntu’ published by Canonical Group Limited.*
  3. Click ‘Get’ and follow any further on screen instructions.


Windows store Ubuntu

Ubuntu confirmation window

The Microsoft Store will handle the download and installation as well as reporting progress.

*At the time this article is being written Ubuntu 20.04 LTS will be installed following this method. 18.04 published by Canonical Group Limited can also be found on the Microsoft Store if needed for compatibility purposes

Launching Ubuntu-

With the Microsoft Store installation complete Ubuntu can now be launched like any other Windows application from the start menu. 

Screen shot showing how you launch Ubuntu from Windows

On first launch Ubuntu will notify you that it is ‘Installing’ and to wait for the process to complete. When the installation finishes you will be prompted to create a new Unix username and password. Note: These credentials do not need to match your windows credentials.

Screen shot showing bash command line

Once complete, and for future launches you will find yourself at the bash command line.

Congratulations! You have completed the setup and installation of Ubuntu Linux Bash terminal for Windows 10!

Note: This blog was originally created on August 1, 2016. It was updated on September 30, 2020 with updated details. 


About the Author: Eric Nachtigal

Eric is a Hardware Applications Engineer for OnLogic which means that he works to find solutions to unique customer challenges as well as validating upcoming technology and products. In his free time, Eric enjoys the great outdoors including camping, hiking, skiing, climbing, and paddling.
Follow OnLogic on LinkedIn


  1. ahmed_eld August 9, 2016 at 6:39 pm

    so,,what the different between that and having ubuntu as complete operation system

  2. Darek Fanton August 10, 2016 at 2:48 pm

    Hi Ahmed, thanks for your question. In general what installing Bash allows you to do is retain the benefits of a Windows operating system and the interface of a Linux environment without having to dual-boot or find another workaround. There are still a number of applications that are more compatible with Windows but many users prefer to work in Linux. In some ways installing Bash gives you the best of both worlds.

  3. Mike Greenawalt February 12, 2019 at 5:17 pm

    I have successfully followed your instructions to install Linux bash on Windows 10, and I can open the shell and execute commands within it. What I want to do is to use some of the Linux tools (grep in particular) on some files that I have created and stored under the Windows environment. I used to have Msys installed on my PC, and it provided for simply saying “cd c:” and it would place one at the top of the Windows file structure. How do I do that with the Ubuntu app on Windows 10?

Leave A Comment


Have a project? Let's talk

More Articles


Learn the 5 ways Fanless Computers can help your business

Get the Whitepaper
View All Articles

OnLogic Industrial Computers

Discover OnLogic's multitude of industrial computers that will help you to advance your IoT project

Shop OnLogic

Learn more at OnLogic.com

OnLogic Industrial PCs: Designed to last. Built to order. Delivered in days. Visit our online store at OnLogic.com