error MSB3644: The reference assemblies for .NETFramework,Version=v1.0 were not found.
in a modern .NET project can come from a typo, not a missing pack. Look at
TargetFramework in the .csproj: a value such as
net10 is read as .NET Framework 1.0. Write net10.0.
The framework name in the message tells you how the SDK understood your value. If it
shows a version or a family you never meant to target, the fix is the spelling of
TargetFramework, not a Developer Pack download.
The error
Determining projects to restore...
Restored ...\TfmLab\TfmLab.csproj (in 758 ms).
C:\Program Files\dotnet\sdk\10.0.403\Microsoft.Common.CurrentVersion.targets(1259,5): error MSB3644: The reference assemblies for .NETFramework,Version=v1.0 were not found. To resolve this, install the Developer Pack (SDK/Targeting Pack) for this framework version or retarget your application. You can download .NET Framework Developer Packs at https://aka.ms/msbuild/developerpacks [...\TfmLab\TfmLab.csproj]
Build FAILED.
The project paths are shortened; nothing else in the output was changed.
Why it happens
Without the dot, the SDK read net10 as a .NET Framework name: the message
says .NETFramework,Version=v1.0. Modern .NET names carry the dot, as in
net10.0. The
SDK accepted the value, restore even reported success, and the failure came only when
the build looked for reference assemblies of a framework that this machine does not
have.
Other misspellings end in the same error with a different name in it. In the same
project, netcore10.0 produced
The reference assemblies for .NETCore,Version=v10.0 were not found and
dotnet10.0 produced
The reference assemblies for .NETPlatform,Version=v10.0 were not found.
We set out to capture NETSDK1013, "The TargetFramework value was not recognized", with
these typos; none of the three produced it on SDK 10.0.403, and every one ended in
MSB3644. Installing a Developer Pack would not have helped any of them; the spelling did.
The fix
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net10.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>
dotnet build
dotnet run
With net10.0 the build reported 0 errors and the app printed
Hello, World!. The quickest way to get the value right is to copy it from a
project that dotnet new created on the same SDK, as this one was before the
edit. If the project targets several frameworks, check every
entry in TargetFrameworks (plural) the same way.
How it was reproduced
A dotnet new console project on .NET SDK 10.0.403 with
TargetFramework edited to net10, then to
netcore10.0 and dotnet10.0, building after each change.
Each produced MSB3644 with the framework names quoted above.
Frequently asked
- Why does MSB3644 say .NETFramework Version v1.0?
- The TargetFramework value has no dot, such as net10. Without the dot the SDK read net10 as .NET Framework version 1.0, as the message shows. Use net10.0.
- Do I need to install a .NET Framework Developer Pack for MSB3644?
- Not when the framework name in the message is one you never meant to target. Here net10, netcore10.0 and dotnet10.0 all gave MSB3644, and correcting the value to net10.0 fixed it.
- What is the correct TargetFramework for .NET 10?
- net10.0, with the dot. It is the value dotnet new console writes on the .NET 10 SDK.
More decoded errors in the Fixes category. If the spelling is right but the SDK is too old for it, see NETSDK1045.