02_Installing EF Core Packages - Maniconserve/EF-Core GitHub Wiki
EF Core is not included in .NET by default and must be installed via NuGet. The two main packages required are:
1. EF Core Database Provider – Enables EF Core to interact with a database. Install the appropriate provider based on your database:
SQL Server → Microsoft.EntityFrameworkCore.SqlServer
SQLite → Microsoft.EntityFrameworkCore.Sqlite
PostgreSQL → Npgsql.EntityFrameworkCore.PostgreSQL
Installation Command:
Install-Package Microsoft.EntityFrameworkCore.SqlServer
2. EF Core Tools – Provides commands for migrations, database updates, and scaffolding.
Installation Command:
Install-Package Microsoft.EntityFrameworkCore.Tools
Note: The Tools package is used for development only.