Skip to content
Docs Try Aspire

Aspire Visual Studio Code extension

The official Aspire extension for VS Code. Run, debug, and deploy your Aspire apps without leaving the editor, with debugging support for C#, Python, Node.js, and more.

FeatureDescription
Run & debugStart your whole app and attach debuggers to every service with F5 F5 F5
DashboardView resources, endpoints, logs, traces, and metrics while your app runs
SidebarBrowse running apphosts and resources in the Activity Bar
IntegrationsAdd databases, queues, and cloud services from the Command Palette
ScaffoldingCreate new Aspire projects from templates
DeployGenerate deployment artifacts or push to cloud targets
MCPLet AI tools like GitHub Copilot see your running app via the Model Context Protocol
Multi-languageDebug C#, Python, Node.js, Azure Functions, and browser apps together
  • Aspire CLI — Install via the Aspire: Install Aspire CLI (stable) command in VS Code, or follow the installation guide.
  • .NET 10 or later — Download .NET.
  • VS Code 1.98 or later.
  1. Open VS Code.
  2. Open the Extensions view ( Command + Shift + X Control + Shift + X Control + Shift + X ).
  3. Search for Aspire and install the extension published by Microsoft.
VS Code Extensions marketplace showing the Aspire extension.

Or install directly from the VS Code Marketplace.

Open your Aspire project in VS Code, or create one with Aspire: New Aspire project from the Command Palette. Run Aspire: Configure launch.json file to set up the debug configuration, then press F5 F5 F5 . The extension builds your apphost, starts your services, attaches debuggers, and opens the dashboard.

VS Code showing the Aspire new project command with template options.

There’s also a built-in walkthrough at Help > Get Started > Get started with Aspire that covers the basics step by step.

Add an entry to .vscode/launch.json pointing at your apphost project:

.vscode/launch.json
{
"type": "aspire",
"request": "launch",
"name": "Aspire: Launch MyAppHost",
"program": "${workspaceFolder}/MyAppHost/MyAppHost.csproj"
}

Or run Aspire: Configure launch.json file from the Command Palette to generate one automatically.

When you press F5 F5 F5 , the extension builds the apphost, starts all resources (services, containers, databases) in the right order, attaches debuggers based on each service’s language, and opens the dashboard.

You can also right-click an AppHost file in the Explorer and select Run Aspire apphost or Debug Aspire apphost.

The command property in the launch config supports more than just running:

  • deploy — Push to your defined deployment targets.
  • publish — Generate deployment artifacts (manifests, Bicep files, etc.).
  • do — Run a specific pipeline step. Set step to the step name.
.vscode/launch.json
{
"type": "aspire",
"request": "launch",
"name": "Aspire: Deploy MyAppHost",
"program": "${workspaceFolder}/MyAppHost/MyAppHost.csproj",
"command": "deploy"
}

For more information, see Aspire publishing and deployment overview.

Customizing debugger settings per language

Section titled “Customizing debugger settings per language”

The debuggers property lets you pass debug configuration specific to a language. Use project for C#/.NET services, python for Python, and apphost for the apphost itself:

.vscode/launch.json
{
"type": "aspire",
"request": "launch",
"name": "Aspire: Launch MyAppHost",
"program": "${workspaceFolder}/MyAppHost/MyAppHost.csproj",
"debuggers": {
"project": {
"console": "integratedTerminal",
"logging": { "moduleLoad": false }
},
"apphost": {
"stopAtEntry": true
}
}
}

The extension adds an Aspire panel to the Activity Bar with a live tree of your resources. In Workspace mode you see resources from the apphost in your current workspace, updating in real time. Switch to Global mode with the toggle in the panel header to see every running apphost on your machine.

Right-click a resource to start, stop, or restart it, view its logs, run resource-specific commands, or open the dashboard.

All commands are available from the Command Palette ( Command + Shift + P Control + Shift + P Control + Shift + P ) under Aspire.

CommandDescription
New Aspire projectCreate a new apphost or starter app from a template
Initialize Aspire in an existing codebaseAdd Aspire to an existing project
Add an integrationAdd a hosting integration (Aspire.Hosting.*)
Update integrationsUpdate hosting integrations and the Aspire SDK
Publish deployment artifactsGenerate deployment manifests
Deploy appDeploy to your defined targets
Execute pipeline stepRun a pipeline step and its dependencies (aspire do)
Configure launch.json fileAdd the Aspire debug config to your workspace
Extension settingsOpen Aspire extension settings
Open local Aspire settingsOpen .aspire/settings.json for this workspace
Open global Aspire settingsOpen ~/.aspire/globalsettings.json
Open Aspire terminalOpen a terminal with the Aspire CLI ready
Install Aspire CLI (stable)Install the latest stable CLI
Install Aspire CLI (daily)Install the daily preview build
Update Aspire CLIUpdate the CLI
Verify Aspire CLI installationCheck that the CLI works

The extension detects each resource’s language and attaches the right debugger. Some languages need a companion extension:

LanguageDebuggerExtension needed
C# / .NETcoreclrC# Dev Kit or C#
PythondebugpyPython
Node.jsjs-debug (built-in)None
Browser appsjs-debug (built-in)None
Azure FunctionsVaries by languageAzure Functions + language extension

Node.js and browser debugging work out of the box — VS Code includes a built-in JavaScript debugger. C# Dev Kit gives you richer build integration than the standalone C# extension, but either works for debugging. Azure Functions debugging supports C#, JavaScript/TypeScript, and Python.

Configure the extension under Settings > Aspire, or jump there with Aspire: Extension settings.

SettingDefaultDescription
aspire.aspireCliExecutablePath""Path to the Aspire CLI. Leave empty to use aspire from PATH.
aspire.dashboardBrowseropenExternalBrowserWhich browser opens the dashboard — system default, or Chrome/Edge/Firefox as a debug session.
aspire.enableAspireDashboardAutoLaunchtrueOpen the dashboard automatically when you start debugging.
aspire.registerMcpServerInWorkspacefalseRegister the Aspire MCP server (see MCP Server Integration).

There are more settings for verbose logging, startup prompts, and polling intervals — run Aspire: Extension settings to see them all.

The extension also provides IntelliSense and validation when editing .aspire/settings.json (workspace-level) and ~/.aspire/globalsettings.json (user-level). Use the Open local/global Aspire settings commands to open them.

The extension can register an Aspire MCP server with VS Code. This lets AI tools — GitHub Copilot included — see your running app’s resources, endpoints, and configuration for better context when helping you write code.

Turn it on by setting aspire.registerMcpServerInWorkspace to true. When enabled, the extension registers the MCP server definition via the Aspire CLI whenever a workspace is open and the CLI is available.

For more information, see Use AI coding agents.

Found a bug or have an idea? File it on the dotnet/aspire repo: