.NET implementations supported by EF Core
We want EF Core to be available to developers on all modern .NET implementations, and we're still working towards that goal. While EF Core's support on .NET Core is covered by automated testing and many applications known to be using it successfully, Mono, Xamarin and UWP have some issues.
Overview
The following table provides guidance for each .NET implementation:
EF Core | 3.1 | 5.0 | 6.0 |
---|---|---|---|
.NET & .NET Core | 3.1 | 5.0 | 6.0 |
.NET Standard(1) | 2.0 | 2.1 | |
.NET Framework(2) | 4.7.2 | ||
Mono | 5.4 | 6.4 | |
Xamarin.iOS(3) | 10.14 | 12.16 | (use .NET 6) |
Xamarin.Mac(3) | 3.8 | 5.16 | (use .NET 6) |
Xamarin.Android(3) | 8.0 | 10.0 | (use .NET 6) |
UWP(4) | 10.0.16299 | (use Windows App SDK) | |
Unity(5) | 2018.1 | 2021.2 | TBD |
Tizen(6) | 4.0 | 6.0 | (use .NET 6) |
(1) .NET Standard has been superseded by a new approach to uniformity. For more information, see The future of .NET Standard.
(2) See the .NET Framework section below.
(3) There are issues and known limitations with Xamarin which may prevent some applications developed using EF Core from working correctly. Check the list of active issues for workarounds.
(4) Install the .NET Core UWP 6.x package. See the Universal Windows Platform section of this article.
(5) There are issues and known limitations with Unity. Check the list of active issues.
(6) EF Core compatibility with Tizen is largely unknown. If you've tried it, we'd love your feedback.
.NET Framework
Applications that target .NET Framework may need changes to work with .NET Standard libraries:
Edit the project file and make sure the following entry appears in the initial property group:
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
For test projects, also make sure the following entry is present:
<GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
If you want to use an older version of Visual Studio, make sure you upgrade the NuGet client to version 3.6.0 to work with .NET Standard 2.0 libraries.
We also recommend migrating from NuGet packages.config to PackageReference if possible. Add the following property to your project file:
<RestoreProjectStyle>PackageReference</RestoreProjectStyle>
Universal Windows Platform
Earlier versions of EF Core and .NET UWP had numerous compatibility issues, especially with applications compiled with the .NET Native toolchain. The new .NET UWP version adds support for .NET Standard 2.0 and contains .NET Native 2.0, which fixes most of the compatibility issues previously reported. EF Core 2.0.1 has been tested more thoroughly with UWP but testing is not automated.
When using EF Core on UWP:
To optimize query performance, avoid anonymous types in LINQ queries. Deploying a UWP application to the app store requires an application to be compiled with .NET Native. Queries with anonymous types have worse performance on .NET Native.
To optimize
SaveChanges()
performance, use ChangeTrackingStrategy.ChangingAndChangedNotifications and implement INotifyPropertyChanged, INotifyPropertyChanging, and INotifyCollectionChanged in your entity types.
Report issues
For any combination that doesn't work as expected, we encourage creating new issues on the EF Core issue tracker. For Xamarin-specific issues use the issue tracker for Xamarin.Android or Xamarin.iOS.
Feedback
Submit and view feedback for