WSL container is now available for public preview

soheilpro1 pts0 comments

WSL container is now available for public preview - Windows Command Line

Skip to main content

Dev Blogs

AI

All .NET posts

.NET MAUI<br>ASP.NET Core<br>Blazor<br>Entity Framework

C++<br>C#<br>F#<br>TypeScript

NuGet<br>Servicing<br>.NET Blog in Chinese

Microsoft for Developers<br>Agent Framework<br>Develop from the cloud<br>Xcode<br>ISE Developer<br>TypeScript<br>PowerShell<br>Python<br>Java<br>Java Blog in Chinese<br>Go<br>Microsoft Edge Dev<br>Microsoft 365 Developer<br>Microsoft Entra Identity Developer<br>Microsoft Entra PowerShell

Visual Studio<br>Visual Studio Code<br>Aspire

All things Azure<br>Azure SDK<br>Azure VM Runtime Team<br>Microsoft Azure<br>Azure Cosmos DB<br>Azure DocumentDB<br>Azure Data Studio<br>Azure SQL<br>DevOps<br>DirectX<br>Microsoft Foundry<br>Power Platform

OData<br>Unified Data Model (IDEAs)

Windows Command Line<br>#ifdef Windows<br>Inside MSIX<br>MIDI and music<br>React Native<br>The Old New Thing<br>Windows Developer

Craig Loewen

Senior Product Manager

At Microsoft Build 2026, we introduced WSL containers, bringing Linux container development directly into Windows through the Windows Subsystem for Linux (WSL). Containers have become a foundational part of modern development – from cloud-native applications and AI workloads to testing and deployment pipelines and WSL containers simplify this experience by providing a built-in, enterprise-ready way to create, run, and manage Linux containers on Windows, without requiring additional third-party tooling.

With a new container CLI for end-to-end container workflows and an API that enables Windows applications to programmatically leverage Linux containers, WSL containers make it easier for developers and organizations to build, test, and run containerized workloads while benefiting from the security, manageability, and integration of the Windows platform.

You can now access the WSL container feature in our latest pre-release of WSL! You can install this release right away by running wsl --update --pre-release, or by downloading and installing it directly from GitHub.

Overview

WSL container adds two new features to WSL: A built in Linux container CLI and an API for Windows applications to run Linux containers as part of their app logic.

WSL container CLI – wslc.exe

When you update to the latest WSL version, you will get a new binary on your path: wslc.exe. You can use this binary to do your full Linux container development workflows, including running, debugging, testing and more!

This CLI tool has a familiar format and capabilities, meaning you can use your existing muscle memory when running Linux containers. For example you can run a full Linux desktop in a container and connect to it like so: wslc run -d --name=webtop -e PUID=1000 -e PGID=1000 -e TZ=Etc/UTC -p 3000:3000 -p 3001:3001 lscr.io/linuxserver/webtop:ubuntu-kde, or check your GPU access with a CUDA script: wslc run --rm --gpus all pytorch/pytorch:2.5.1-cuda12.4-cudnn9-runtime python -c "import torch; print(torch.cuda.is_available()); print(torch.cuda.get_device_name(0))". Lastly this also includes a built in alias for container.exe which just runs wslc.exe so you can use the container command or wslc, whichever you prefer.

WSL container API

Windows applications can now also directly use containers as part of their application logic. WSL now ships a Nuget package that is available at nuget.org and also on the WSL releases page. This includes support for C, C++ and C#.

Now your native Windows applications can make use of Linux for their production workflows. This can be especially useful for reusing existing Linux specific code, taking cloud applications and running them locally, or containing a Linux process’ access to resources on the host.

This API also integrates with MSBuild and CMake, so you can just add a few lines to your project files and the container build and deploy steps can all be part of your application’s build process – no manual steps required! Git clone and try a sample for yourself or check out the full API reference!

Learn more and see demos

You can view this presentation from BUILD 2026 to learn more about the use cases and see demos of these features in action. Additionally you can visit our docs page to get in depth guides and sample code.

Integration with enterprise tools

We are making sure that WSL’s great integration with enterprise tooling extends to WSL container as well.

Monitor security events in containers with Microsoft Defender for Endpoint (MDE)

WSL’s existing MDE plugin is updated to also be aware of Linux container events, providing you the same coverage whether you are using a WSL distro or containers. Currently this feature is available as part of a private preview which you can sign up for here.

Manage WSL container settings with Intune

We are also adding new management settings for WSL container. You will be able to control whether people can use WSL distros, or containers in your organization, and also specify an allowlist of which container registries can be used to pull new container images. One of our big aims for this...

container linux windows containers microsoft azure

Related Articles