| title | Deploy ASP.NET container app to Container Registry |
|---|---|
| description | Use Visual Studio Container Tools to deploy a containerized ASP.NET or ASP.NET Core web app to Azure Container Registry. |
| author | ghogen |
| ms.devlang | dotnet |
| ms.topic | how-to |
| ms.subservice | container-tools |
| ms.date | 5/14/2026 |
| ms.author | ghogen |
This tutorial walks you through using Visual Studio to publish your containerized application to an Azure Container Registry.
If you don't have an Azure subscription, create a free account before you begin.
::: moniker range="vs-2022"
-
Install Visual Studio with the ASP.NET and web development workload.
-
Install Docker Desktop for Windows. :::moniker-end
::: moniker range="visualstudio"
-
Install Visual Studio, or for Podman support, Visual Studio 2026, with the ASP.NET and web development workload.
-
Install Docker Desktop for Windows or Podman Desktop.
:::moniker-end
The following steps guide you through creating a basic ASP.NET Core app that you use in this tutorial. If you already have a project, you can skip this section.
:::moniker range=">=vs-2022"
[!INCLUDE create-aspnet5-app]
::: moniker-end
::: moniker range=">=vs-2022"
-
Right-click your project in Solution Explorer and choose Publish. The Publish dialog opens.
-
On the Target tab, select Docker Container Registry, and then select Next.
:::image type="content" source="media/container-tools/vs-2022/docker-container-registry.png" border="false" alt-text="Screenshot that shows the Publish dialog and how to choose Docker Container Registry.":::
-
On the Specific target tab, select Azure Container Registry, and then select Next.
-
On the Registry tab, select the Create new (+) option at the right:
:::image type="content" source="media/container-tools/vs-2022/select-existing-or-create-new-azure-container-registry.png" border="false" alt-text="Screenshot of the Publish dialog that shows how to choose Create New Azure Container Registry.":::
-
Fill in your desired values in the Azure Container Registry screen.
Setting Suggested value Description DNS Prefix Globally unique name Name that uniquely identifies your container registry. Subscription Your subscription The Azure subscription to use. Resource Group Your resource group Name of the resource group in which to create your container registry. Select New to create a new resource group. SKU "Standard" Select the service tier of the container registry. Registry Location A nearby location Choose a location in a region close to you or close to other services that you expect to use the container registry. :::image type="content" source="media/container-tools/vs-2022/vs-azure-container-registry-provisioning-dialog.png" border="false" alt-text="Screenshot that shows how to enter values in the dialog to create a new Azure Container Registry.":::
-
After you enter the resource values, select Create.
Visual Studio validates the property values and creates the new container resource. When the process completes, Visual Studio returns to the Publish dialog and selects the new container in the list.
-
Select Finish to publish the new container.
::: moniker-end
You can now pull the container from the registry to any host capable of running Docker images, such as Azure Container Instances.