Tutorials Entity Framework Core Tutorial
Installing Entity Framework Core
Installing Entity Framework Core: free step-by-step lesson with examples, common mistakes, and interview tips — part of Entity Framework Core Tutorial on Toolliyo Academy.
On this page
Entity Framework Core Tutorial · Lesson 4 of 100
Installing Entity Framework Core
Beginner → Intermediate → Advanced → Professional
Beginner · 1 — Foundations · ~6 min · Module 1: EF Core Fundamentals
What is this?
EF Core arrives as NuGet packages on your project plus the dotnet-ef global tool for migrations. The SQL Server provider package wires EF to LocalDB or Azure SQL.
Why should you care?
Without Microsoft.EntityFrameworkCore.SqlServer and dotnet-ef, ShopNest cannot define DbContext or evolve schema through migrations.
See it live — copy this example
Paste into a .NET project with EF Core packages, then run with LocalDB/SQL Server (dotnet ef / dotnet run).
# ShopNest.Infrastructure
dotnet add package Microsoft.EntityFrameworkCore.SqlServer --version 8.*
dotnet add package Microsoft.EntityFrameworkCore.Design --version 8.*
dotnet tool install --global dotnet-ef
dotnet ef --version
What happened?
- SqlServer is the runtime provider.
- Design supports migrations at build/design time.
- dotnet-ef is the CLI for migrations add and database update.
Practice next
- Run dotnet --version and confirm 8.x or 9.x SDK.
- Create ShopNest.Infrastructure class library if missing.
- Run the package and tool commands from the example.
- Run dotnet list package | findstr EntityFramework to audit versions across projects.
- Install dotnet-ef with a specific version: dotnet tool install --global dotnet-ef --version 8.*
Remember
NuGet packages bring EF Core into the solution. dotnet-ef enables migration CLI commands. Provider package must match your database engine.
ShopNest CI bootstrap
Azure DevOps pipeline runs dotnet restore after pinning EF Core 8 packages in ShopNest.Infrastructure.
Outcome: Every developer and build agent shares the same EF tooling versions.
Interview prep for this lesson
Practice these questions aloud after reading—each links to a full structured answer.
Sign in to ask a question or upvote helpful answers.
No questions yet — be the first to ask!