# ASP.NET Core Error Tracking and Performance Monitoring

> See here how you can use actionable insights to easily diagnose, resolve, & optimize the performance of your ASP.NET Core application. Get started for free now.

**URL:** https://sentry.io/for/aspnetcore/

---

**Documentation:** [https://docs.sentry.io/platforms/dotnet/guides/aspnetcore/](https://docs.sentry.io/platforms/dotnet/guides/aspnetcore/)

## Install

Add the Sentry dependency:

```bash
dotnet add package Sentry.AspNetCore
```

Add Sentry to `Program.cs` through the `WebApplicationBuilder`:

```csharp
var builder = WebApplication.CreateBuilder(args);

builder.WebHost.UseSentry(options =>
{
    options.Dsn = "https://<key>@sentry.io/<project>";
    // When configuring for the first time, to see what the SDK is doing:
    options.Debug = true;
    // Set TracesSampleRate to 1.0 to capture 100% of transactions for tracing.
    // We recommend adjusting this value in production.
    options.TracesSampleRate = 1.0;
});
```

See the [ASP.NET Core docs](https://docs.sentry.io/platforms/dotnet/guides/aspnetcore/) for full setup options.

## Features

### ASP.NET Core Error Monitoring with Complete Stack Traces

See ASP.NET Core stack trace details like filename and line number so you never have to guess. Filter and group ASP.NET Core exceptions intuitively to eliminate noise. Monitor errors at scale without impacting throughput in production.

### ASP.NET Core Performance Monitoring

Quickly identify ASP.NET Core performance issues before they become downtime with [Tracing](/product/tracing/). View the entire end-to-end distributed trace to see the exact, poor-performing API call and surface any related errors.

### Fill In The Blanks About ASP.NET Core Errors

Expose the important events that led to each ASP.NET Core exception: debug logs, network requests, database queries, past errors.

### See the Full Picture of Any ASP.NET Core Exception

With Sentry's exceptional exception handling in ASP.NET Core, you can triage quickly based on specific parameters like HTTP request, workflow stage, and hostname for each issue. Set custom tags to recreate the error environment relevant to your app, business concerns, and users.

---

*Source: [sentry.io/for/aspnetcore/](https://sentry.io/for/aspnetcore/)*
