NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
NuGet, #99 most downloaded on NuGet
NLog is a logging platform for .NET with rich log routing and management capabilities. NLog supports traditional logging, structured logging and the combination of both. Supported platforms: - .NET 6, 7, 8, 9 and 10 - .NET Standard 2.0 and 2.1 - .NET Framework 3.5 - 4.8 - Xamarin Android + iOS (.NET Standard) - Mono 4 For integrating NLog with Microsoft.Extensions.Logging, check: https://www.nuget.org/packages/NLog.Extensions.Logging For using NLog with ASP.NET Core, check: https://www.nuget.org/packages/NLog.Web.AspNetCore
Latest stable
6.2.2
Last release 1 months ago
15 Oct 2026
Ships on a steady schedule
a new release about every 4 weeks
Nearly every release is documented
notes for 60 of the last 60 stable releases
98 versions withdrawn
withdrawn after publishing
127 years old
222 releases · first in 1900
Drag across the ruler to compare, or tap a release to open it.
Fixed MailTarget issue with reading "from" from .config
Fixed MailTarget issue with reading "from" from .config
See milestone
MailTarget: using "from" from .config
Your coding agent can read these notes before it upgrades. Set up the MCP server →
Fixes for bugs introduced in NLog 4.3. All reported issues are now fixed.
Fixes for bugs introduced in NLog 4.3. All reported issues are now fixed.
${var:myvar} with the FileTarget"allLayouts is null. Call base.InitializeTarget()", which was even an issue when throwExceptions = false.Filetarget could throw "Thread was being aborted"See milestone
Nothing published for this version
Support Windows Phone 8, Xamarin Android and Xamarin iOS (beta)
<connectionStrings>MappedDiagnosticsLogicalContextGetLogger() and GetCurrentClassLogger()Logger.Swallow(Task task)Among others:
${callsite} works now for async methods!${basedir}${variable}${processtime}: incorrect milliseconds formatting${processtime}: fix incorrect negative time (rounding issue)See milestone
- #1348 Fix nullref + fix relative path for file archive (@304NotModified) - #1352 Fix for writing log file to root path (@304NotModified) - #1357 aut
- #1335 Fix all build warnings (@304NotModified) - #1336 Throw NLogConfigurationException if TimeToSleepBetweenBatches <= 0 (@vincechan) - #1333 Fix $
- #1323 Add TimeStamp options to XML, Appsetting and environment var (@304NotModified) - #1286 Easier api: AddRule methods, fix AllTargets crash, fix
<connectionStrings> (app.config etc) (@304NotModified)cref in comments. (@304NotModified)Nothing published for this version
- #1220 FileTarget: Add internal logging for archive date. (@bhaeussermann) - #1214 Better unit test cleanup between tests + fix threadsafe issue Scan
Support for Windows Phone 8 (beta)
${basedir} anymore!See full list: https://github.com/NLog/NLog/issues?q=milestone%3A4.3+is%3Aclosed
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Performance improvements (CPU & Memory) for the FileTarget.
Performance improvements (CPU & Memory) for the FileTarget.
Changes:
CleanupFileName by @epignosisx (https://github.com/NLog/NLog/pull/1063)CleanupFileName on filetarget for faster writing when using dynamic (=non-fixed) file name. Default true (=backwards-compatible)Fixed assembly file version. Same code as NLog 4.2.1.
Fixed assembly file version. Same code as NLog 4.2.1.
See GitHub issue
Show warning for Databasetarget.UseTransactions instead of exception.
Nothing published for this version
Performance Counter Target: it's now possible to configure the step size for the counter target. Before the step size was always one.
pickupDirectoryLocation and deliveryMethod are configurable from the NLog config.clearCache option has been added for more control over clearing the cache..zip to compressed archive when archiveName isn't specified.useSystemNetMailSettings was false, some settings were still used from the <mailSettings> of the .Net config.In more detail, see news post
.zip to compressed filename when archiveName isn't specified (@bhaeussermann)Nothing published for this version
Fluent API: Added .Properties for easier adding of multiple (event)properties.
Features:
.Properties for easier adding of multiple (event)properties.Bug fixes:
AllEventPropertiesLayoutRenderer was not ThreadAgnostic.ReconfigExistingLoggers.Other:
MDLC now also supports objects, like MDC,GDC and NDC (those we're added in 4.1.0)
Features:
Bug fixes:
Other:
See news post.
Nothing published for this version
New features, bug-fixes and easier upgrade to NLog 4.x
New features, bug-fixes and easier upgrade to NLog 4.x
<extensions> needs to be the first element in the config (@304NotModified)ICreateFileParameters (@304NotModified)IncludeCallerInformation option. (@304NotModified)Nothing published for this version
Nothing published for this version
We reverted an unneeded breaking change in MailTarget. The SMTP property is not required anymore. This is consistent with 3.x.
Patch release for 4.0. This release fixes the following problems:
MailTarget. The SMTP property is not required anymore. This is consistent with 3.x.OverflowExceptions in 64-bit runtime. This was a bug since NLog 2.0.See also news post
See milestone and news post
Nothing published for this version
See milestone
See milestone
This release add five new features to NLog and fixes more than 20 bugs. See the release post or the full changelog
This release add five new features to NLog and fixes more than 20 bugs. See the release post or the full changelog
Contains mostly bug fixes, see full changelog
Contains mostly bug fixes, see full changelog
Removes support for some of the older frameworks supported in NLog 2.x:
Removes support for some of the older frameworks supported in NLog 2.x:
Apart from this, this release contains mostly bug fixes. See the NLog 3.0 change log for all changes.
Better support for partial trust (#67, #117, #144)
Most notable changes:
See full changelog here https://github.com/NLog/NLog/issues?milestone=2&state=closed
- #197 Better request queue logging (@kichristensen) - #192 Allow Form Control Target to specify append direction (@simongh) - #182 Fix locks around l
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
One column per quarter.