Dynamics 365 Business Central on-prem: be careful when referencing .NET assemblies across versions.
When upgrading Business Central on-premises and using custom extensions with .NET assemblies, ensure assemblies are compiled for .NET Standard if targeting version 21 or later, even if the AL compiler allows .NET Framework versions locally. The runtime requires .NET Standard compliance to publish successfully.

post Stefano Demiliani
Key points
- Business Central version 21 and later only support .NET Standard compiled add-ins at runtime, not .NET Framework versions
- The AL compiler accepts both .NET Standard and .NET Framework assemblies during local compilation, masking compatibility issues
- Extensions must be compiled with .NET Standard assemblies when published to service tiers running version 21 or later
- Reload Visual Studio Code after updating assemblies in probing paths to avoid caching old assembly versions
Context
- Features: .NET add-in support, .NET Standard runtime, assembly probing paths, extension publication
- Versions: 14, 21, 25
Source: Stefano Demiliani, community blog. Summary, key points and quotes are derived (CONTENT-NOTICE.md); read the original for the full text.