Answer
Dependency Injection (DI) in ASP.NET Core is the built-in mechanism for constructing and wiring application services.
The framework provides a first-class DI container that:
- Creates and manages service lifetimes.
- Resolves dependencies for controllers, Razor Pages, middleware, and other components.
- Encourages testable, loosely coupled code.
Having DI built-in removes the need for static helpers or service locators and standardizes how dependencies are managed across the whole stack.