Scrutinator 2.0.0

dotnet add package Scrutinator --version 2.0.0
                    
NuGet\Install-Package Scrutinator -Version 2.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Scrutinator" Version="2.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Scrutinator" Version="2.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Scrutinator" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Scrutinator --version 2.0.0
                    
#r "nuget: Scrutinator, 2.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Scrutinator@2.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Scrutinator&version=2.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Scrutinator&version=2.0.0
                    
Install as a Cake Tool

Scrutinator

Scrutinator is a lightweight diagnostic tool for inspecting ASP.NET Core dependency injection containers. It captures your IServiceCollection, analyzes registrations, and serves a small dashboard that lists services, lifetimes, and potential captive dependency issues. And now with a fancy Log Scrutinating Dashboard.

Features

  • Lists all registered services with their implementation types, lifetimes, and namespaces.
  • Filters by lifetime and text search in the embedded dashboard.
  • Optional captive dependency warnings (singleton depending on scoped services).
  • Hides Microsoft/System services by default to reduce noise.
  • Optional auto-open of the dashboard on app start.

Quick start

Install the package:

dotnet add package Scrutinator

Wire it up in your application:

using Scrutinator.Middleware;

var builder = WebApplication.CreateBuilder(args);

builder.Services
    .AddScrutinatorDI()
    .AddScrutinatorLog();
    // Or, if you have a custom log, like a ILog
    .AddScrutinatorCustomLogger<ILog>();
    
var app = builder.Build();

app
    .UseScrutinatorDI()
    .UseScrutinatorLog();    

app.Run();

For DI: Open the dashboard at http(s)://<host>/di-scrutinator.

For Logs: Open the dashboard at http(s)://<host>/log-scrutinator.

Configuration

Configure options when adding the middleware:

app.UseScrutinatorDI(options =>
{
    options.IncludeSystemServices = false;
    options.ScanForCaptiveDependencies = true;
    options.OpenDashboardAutomatically = true;
});

app.UseScrutinatorLog(options =>
{
    options.OpenDashboardAutomatically = true;
});

app.UseScrutinatorPackage(opts =>
{
    opts.OpenDashboardAutomatically = true;
});

Options:

  • IncludeSystemServices (default: false): include System.* and Microsoft.* registrations.
  • ScanForCaptiveDependencies (default: true): scan singleton constructors for scoped dependencies.
  • OpenDashboardAutomatically (default: true): open the dashboard in the default browser on app start.

How it works

DI - Scrutinator

Scrutinator captures the IServiceCollection via AddDIScrutinator(), then analyzes it when the dashboard route is hit. The UI is an embedded HTML file that renders the serialized report.

Captive dependency analysis is best-effort and only runs when a singleton has a concrete ImplementationType. Registrations based on factories or instances cannot be fully inspected.

Log - Scrutinator

Scrutinator captures logs from the ILogger provider and analyzes them when the dashboard route is hit.

Package - Scrutinator

Scrutinator captures the packages from the Assembly and analyzes it when the dashboard route is hit.

Development

The project's repo includes a Sandbox project that demonstrates usage:

dotnet run --project Sandbox

dotnet build --configuration Release
dotnet pack --configuration Release

Then navigate to https://localhost:<port>/di-scrutinator or https://localhost:<port>/log-scrutinator or https://localhost:<port>/package-scrutinator in your browser.

Product 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.0.0 116 7/3/2026
1.1.5 116 2/27/2026
1.1.2 120 2/10/2026
1.0.3 118 2/9/2026
1.0.2 119 2/9/2026
0.0.5 122 2/8/2026