NLog.Web.AspNetCore 6.0.2
NLog.Web.AspNetCore
Integrates NLog as Logging provider for the ASP.NET Core platform, by just calling UseNLog() with the application host-builder.
Providing features like:
- Enrich logging output with additional details from active HttpContext using NLog LayoutRenderers, by just updating the NLog configuration.
- Supports middleware injection for HTTP Request Logging and HTTP Response Logging.
- Routing logging output to multiple destinations via the available NLog Targets
- Rendering logging output into standard formats like JSON, CVS, W3C ELF and XML using NLog Layouts.
- Contributions are always welcome, by creating a pull request.
Supported platforms:
- ASP.NET Core 6, 7, 8 and 9
- ASP.NET Core 2, .NET Standard 2.0 and .NET 4.6.1+
Registration of NLog.Web.AspNetCore in the NLog.config file:
<extensions>
<add assembly="NLog.Web.AspNetCore"/>
</extensions>
Registration of NLog.Web.AspNetCore can also be performed with fluent setup:
NLog.LogManager.Setup().LoadConfigurationFromAppSettings();
Useful Links:
No packages depend on NLog.Web.AspNetCore.
ChangeLog:
- Updated dependency NLog v6.0.2
List of major changes in NLog v6.0: https://nlog-project.org/2025/04/29/nlog-6-0-major-changes.html
Full changelog: https://github.com/NLog/NLog.Web/releases
List of available Layout Renderers: https://nlog-project.org/config/?tab=layout-renderers&search=package:nlog.web.aspnetcore
.NET Framework 4.6.2
- Microsoft.AspNetCore.Hosting.Abstractions (>= 2.3.0)
- Microsoft.AspNetCore.Http (>= 2.3.0)
- Microsoft.AspNetCore.Routing.Abstractions (>= 2.3.0)
- NLog.Extensions.Logging (>= 6.0.2)
.NET 6.0
- NLog.Extensions.Logging (>= 6.0.2)
.NET 8.0
- NLog.Extensions.Logging (>= 6.0.2)
.NET Standard 2.0
- Microsoft.AspNetCore.Hosting.Abstractions (>= 2.3.0)
- Microsoft.AspNetCore.Http (>= 2.3.0)
- Microsoft.AspNetCore.Routing.Abstractions (>= 2.3.0)
- NLog.Extensions.Logging (>= 6.0.2)
| Version | Downloads | Last updated |
|---|---|---|
| 6.0.5 | 4 | 10/12/2025 |
| 6.0.4 | 7 | 09/12/2025 |
| 6.0.3 | 8 | 08/12/2025 |
| 6.0.2 | 9 | 07/21/2025 |
| 6.0.1 | 14 | 06/30/2025 |
| 6.0.0 | 12 | 06/23/2025 |
| 6.0.0-rc4 | 12 | 06/17/2025 |
| 6.0.0-rc3 | 14 | 06/17/2025 |
| 6.0.0-rc2 | 11 | 06/17/2025 |
| 5.5.0 | 13 | 06/17/2025 |
| 5.4.0 | 15 | 06/17/2025 |
| 5.3.15 | 12 | 06/17/2025 |
| 5.3.14 | 12 | 06/17/2025 |
| 5.3.13 | 12 | 06/17/2025 |
| 5.3.12 | 11 | 06/17/2025 |
| 5.3.11 | 12 | 06/17/2025 |
| 5.3.10 | 12 | 06/17/2025 |
| 5.3.9 | 12 | 06/17/2025 |
| 5.3.8 | 13 | 06/17/2025 |
| 5.3.7 | 14 | 06/17/2025 |
| 5.3.5 | 13 | 06/17/2025 |
| 5.3.4 | 14 | 06/17/2025 |
| 5.3.3 | 11 | 06/17/2025 |
| 5.3.2 | 10 | 06/17/2025 |
| 5.3.1 | 14 | 06/17/2025 |
| 5.3.0 | 14 | 06/17/2025 |
| 5.2.3 | 15 | 06/17/2025 |
| 5.2.2 | 16 | 06/17/2025 |
| 5.2.1 | 15 | 06/17/2025 |
| 5.2.0 | 13 | 06/17/2025 |
| 5.1.5 | 14 | 06/17/2025 |
| 5.1.4 | 15 | 06/17/2025 |
| 5.1.2 | 14 | 06/17/2025 |
| 5.1.1 | 14 | 06/17/2025 |
| 5.1.0 | 10 | 06/17/2025 |
| 5.0.0 | 12 | 06/17/2025 |
| 4.15.0 | 13 | 06/17/2025 |
| 4.14.0 | 13 | 06/17/2025 |
| 4.13.0 | 13 | 06/17/2025 |
| 4.13.0-readme-preview | 14 | 06/17/2025 |
| 4.12.0 | 11 | 06/27/2025 |
| 4.11.0 | 12 | 06/17/2025 |
| 4.10.0 | 12 | 06/17/2025 |
| 4.9.3 | 12 | 06/27/2025 |
| 4.9.2 | 13 | 06/17/2025 |
| 4.9.1 | 12 | 06/17/2025 |
| 4.9.0 | 13 | 06/17/2025 |
| 4.8.6 | 12 | 06/17/2025 |
| 4.8.5 | 13 | 06/17/2025 |
| 4.8.4 | 12 | 06/17/2025 |
| 4.8.3 | 12 | 06/28/2025 |
| 4.8.2 | 13 | 06/17/2025 |
| 4.8.1 | 10 | 06/17/2025 |
| 4.8.0 | 13 | 06/17/2025 |
| 4.7.1 | 15 | 06/17/2025 |
| 4.7.0 | 13 | 06/17/2025 |
| 4.6.0 | 13 | 06/17/2025 |
| 4.5.4 | 11 | 06/17/2025 |
| 4.5.3 | 12 | 06/17/2025 |
| 4.5.2 | 14 | 06/17/2025 |
| 4.5.1 | 12 | 06/17/2025 |
| 4.5.0 | 13 | 06/17/2025 |
| 4.5.0-rc3 | 13 | 06/04/2025 |
| 4.4.1 | 12 | 06/17/2025 |
| 4.4.0 | 11 | 06/17/2025 |
| 4.3.1 | 12 | 06/17/2025 |
| 4.3.0 | 13 | 06/17/2025 |
| 4.2.4 | 14 | 06/17/2025 |
| 4.2.3 | 12 | 06/17/2025 |