DEV Community

Cover image for How to debug an Azure App Service with Visual Studio 2022
Emanuele Bartolesi
Emanuele Bartolesi

Posted on

3 2

How to debug an Azure App Service with Visual Studio 2022

Sometimes (for me very often 🤣) when you deploy an app to Azure doesn't functioning properly. It happens.
The app still works on your machine and it's difficult to understand the reason behind.

works on my machine

With Visual Studio you can easily attach the debugger to the App Service process and debug the "remote" application as it's running locally.

From the main menu, click on Debug -> Attach to process.
From the new window, select Microsoft Azure App Services as Connection type.

Microsoft Azure App Services

Click on the Find... button and in the new dialog, browse in your Azure subscriptions and select the right app service.

select the app service

At this point, Visual Studio, starts to load assembly from the remote service and you should see the next screen.

loading remote service

After a while, you should see the list on the processes on the remote service and the w3wp.exe process should appear in the list.

w3wp.exe process

Select the process and then click to the Attach button on the bottom right of the window.

Enjoy your debugging session on the App Service 🙂

Speedy emails, satisfied customers

Postmark Image

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up

Top comments (0)

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay