Aspire.Hosting.Browsers
13.6.4-preview.1.26523.11
Prefix Reserved
dotnet add package Aspire.Hosting.Browsers --version 13.6.4-preview.1.26523.11
NuGet\Install-Package Aspire.Hosting.Browsers -Version 13.6.4-preview.1.26523.11
<PackageReference Include="Aspire.Hosting.Browsers" Version="13.6.4-preview.1.26523.11" />
<PackageVersion Include="Aspire.Hosting.Browsers" Version="13.6.4-preview.1.26523.11" />
<PackageReference Include="Aspire.Hosting.Browsers" />
paket add Aspire.Hosting.Browsers --version 13.6.4-preview.1.26523.11
#r "nuget: Aspire.Hosting.Browsers, 13.6.4-preview.1.26523.11"
#:package Aspire.Hosting.Browsers@13.6.4-preview.1.26523.11
#addin nuget:?package=Aspire.Hosting.Browsers&version=13.6.4-preview.1.26523.11&prerelease
#tool nuget:?package=Aspire.Hosting.Browsers&version=13.6.4-preview.1.26523.11&prerelease
Browser logs hosting integration
Use this integration to model, configure, and orchestrate tracked Chromium browser sessions for web resources in an Aspire solution during local development.
Getting started
Prerequisites
- A Chromium-based browser, such as Microsoft Edge, Google Chrome, or Chromium, installed on the development machine.
- A resource that exposes an HTTP or HTTPS endpoint for a browser to open.
Add the integration
From your AppHost directory, add the Aspire.Hosting.Browsers integration with the Aspire CLI:
aspire add Aspire.Hosting.Browsers
The browser logs API is experimental. C# callers must opt in by suppressing ASPIREBROWSERLOGS001, as shown below.
Usage example
Then, in the AppHost, add browser logs to a web frontend resource with either C# or TypeScript:
C#
#pragma warning disable ASPIREBROWSERLOGS001
var builder = DistributedApplication.CreateBuilder(args);
builder.AddProject<Projects.WebFrontend>("web")
.WithExternalHttpEndpoints()
.WithBrowserLogs();
builder.Build().Run();
#pragma warning restore ASPIREBROWSERLOGS001
TypeScript
import { createBuilder } from "./.aspire/modules/aspire.mjs";
const builder = await createBuilder();
await builder.addProject("web", "../WebFrontend/WebFrontend.csproj")
.withExternalHttpEndpoints()
.withBrowserLogs();
await builder.build().run();
Start the AppHost, then select Open tracked browser on the web-browser-logs child resource in the dashboard. Browser console messages and errors appear in that resource's console logs. Use Capture screenshot to save a screenshot as a command artifact.
The tracked browser uses an Aspire-managed user data directory, not your normal browser profile. Browser log resources are excluded from publishing.
Additional documentation
- https://aspire.dev/integrations/gallery/
- https://aspire.dev/integrations/devtools/browser-logs/
- https://chromedevtools.github.io/devtools-protocol/
Feedback & contributing
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- Aspire.Hosting (>= 13.6.4)
- AspNetCore.HealthChecks.Uris (>= 9.0.0)
- Google.Protobuf (>= 3.36.1)
- Grpc.AspNetCore (>= 2.83.0)
- Grpc.Net.ClientFactory (>= 2.83.0)
- Grpc.Tools (>= 2.83.0)
- Hex1b (>= 0.168.0)
- KubernetesClient (>= 19.0.2)
- MessagePack (>= 2.5.307)
- Microsoft.Extensions.Configuration.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Configuration.Binder (>= 10.0.12)
- Microsoft.Extensions.Configuration.EnvironmentVariables (>= 10.0.12)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Diagnostics.HealthChecks (>= 8.0.31)
- Microsoft.Extensions.FileSystemGlobbing (>= 10.0.12)
- Microsoft.Extensions.Hosting (>= 10.0.12)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Http (>= 10.0.12)
- Microsoft.Extensions.Logging (>= 10.0.12)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Options (>= 10.0.12)
- Microsoft.Extensions.Primitives (>= 10.0.12)
- ModelContextProtocol (>= 1.4.1)
- Newtonsoft.Json (>= 13.0.4)
- OpenTelemetry.Exporter.OpenTelemetryProtocol (>= 1.17.0)
- OpenTelemetry.Extensions.Hosting (>= 1.17.0)
- Polly.Core (>= 8.7.0)
- Semver (>= 3.0.0)
- StreamJsonRpc (>= 2.25.29)
- System.IO.Hashing (>= 10.0.12)
- System.Text.Json (>= 10.0.12)
- YamlDotNet (>= 18.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on Aspire.Hosting.Browsers:
| Repository | Stars |
|---|---|
|
exceptionless/Exceptionless
Exceptionless application
|
| Version | Downloads | Last Updated |
|---|---|---|
| 13.6.4-preview.1.26523.11 | 644 | 10/24/2026 |
| 13.6.3-preview.1.26521.2 | 798 | 10/21/2026 |
| 13.6.2-preview.1.26519.11 | 626 | 10/20/2026 |
| 13.6.1-preview.1.26506.6 | 17,832 | 10/7/2026 |
| 13.6.0-preview.1.26479.8 | 9,800 | 9/29/2026 |
| 13.5.4-preview.1.26464.4 | 8,889 | 9/15/2026 |
| 13.5.3-preview.1.26425.3 | 16,614 | 8/25/2026 |
| 13.5.2-preview.1.26421.6 | 6,532 | 8/21/2026 |
| 13.5.1-preview.1.26420.4 | 1,094 | 8/20/2026 |
| 13.5.0-preview.1.26417.10 | 4,221 | 8/18/2026 |
| 13.4.6-preview.1.26319.6 | 76,627 | 6/19/2026 |
| 13.4.5-preview.1.26316.12 | 3,052 | 6/17/2026 |
| 13.4.4-preview.1.26314.3 | 1,074 | 6/15/2026 |
| 13.4.3-preview.1.26305.13 | 9,205 | 6/8/2026 |
| 13.4.2-preview.1.26303.6 | 7,453 | 6/3/2026 |
| 13.4.1-preview.1.26303.3 | 96 | 6/3/2026 |
| 13.4.0-preview.1.26281.18 | 5,544 | 6/1/2026 |
| 13.3.5-preview.1.26270.6 | 5,552 | 5/21/2026 |
| 13.3.4-preview.1.26268.8 | 9,402 | 5/19/2026 |
| 13.3.3-preview.1.26264.13 | 46,395 | 5/15/2026 |