Glossary / .NET SDK and target frameworks
.NET SDK and target frameworks
The .NET SDK provides the dotnet CLI, MSBuild-based project system, compilers, workload tooling, and targeting packs used to restore, build, test, and publish .NET applications. A target framework moniker (TFM), such as net10.0, declares the API surface and runtime family a project targets; it is separate from the SDK version installed to build it.
SDK, runtime, and TFM
The SDK can build projects for supported target frameworks when the appropriate reference packs are available, and it may download them during restore. The runtime executes applications; the target framework determines compile-time APIs and compatibility contracts. TargetFramework selects one TFM, while TargetFrameworks enables multi-targeting. Framework-dependent deployment expects a compatible runtime installed; self-contained deployment includes a runtime for a selected RID, with tradeoffs in size and servicing.
global.json can select an SDK version and roll-forward policy for a repository. SDK selection is not the same as TargetFramework; a project may build with one SDK and target a different supported .NET version. Legacy .NET Framework, modern .NET, and .NET Standard have distinct compatibility and platform roles.
Engineering guidance
Pin and provision the SDK in developer and CI environments, target a supported TFM, and plan upgrades against the .NET release/support schedule. Multi-target libraries should test each TFM and conditional compilation path. Keep RID and deployment choices explicit; a successful compile does not prove the target runtime is installed or operational.
Interview questions
- SDK vs runtime? SDK builds and publishes; runtime executes applications.
- What does a TFM specify? The API and framework compatibility target for the project.
- What does
global.jsoncontrol? SDK selection/roll-forward, not the app's target framework. - Framework-dependent vs self-contained? Runtime supplied by machine versus bundled with app for a target platform.
- Why multi-target a library? To expose compatible builds/API surfaces to consumers on different frameworks.