Start here. This is the direct spoken answer to practice first.
Why this matters
DI lifetimes are not just container settings. In web APIs, wrong lifetimes can leak state across users, capture disposed services, or make background services fail in subtle ways.
ASP.NET Core commonly uses transient, scoped, and singleton lifetimes. Transient services are created each time they are requested, scoped services live for one request scope, and singletons live for the application lifetime. In APIs, scoped is common for request-oriented services and EF Core DbContext. A wrong lifetime can create bugs like shared state between users or using a disposed dependency.