The short answer: .NET Core interviews usually cover the platform (what .NET is today, versions and support), C# fundamentals, ASP.NET Core (middleware, dependency injection, configuration, routing), data access with Entity Framework Core, async and performance, and testing, plus classic ASP.NET for teams maintaining older apps. Senior roles add design questions: how you’d build, scale and observe a real service. Below are the common questions with short answers, grouped by area, with the code you should be able to write on a whiteboard.
The platform
“What’s the difference between .NET Core, .NET and .NET Framework?”
.NET Framework is the original Windows-only framework. .NET Core was the cross-platform, open-source rewrite. From version 5 onward it dropped “Core” from the name and is simply .NET (.NET 5, 6, 7 and so on). ASP.NET Core and Entity Framework Core kept “Core” in their names.
“Which version would you use for a new project?”
The current long-term support release. Microsoft’s support policy lists .NET 10 (released 11 November 2025) as LTS, supported until 14 November 2028. .NET 8 (LTS) and .NET 9 (STS) both reach end of support on 10 November 2026, and .NET 11 is in release candidate as of September 2026.
“What’s the difference between LTS and STS?”
Microsoft’s definition: “LTS releases are supported for three years after the initial release.” STS (standard term support) releases are supported for two years. New major versions ship every November.
“What are the CLR, JIT and garbage collector?”
The CLR (common language runtime) runs .NET code. Code compiles to intermediate language (IL), which the JIT (just-in-time compiler) turns into machine code at run time. The garbage collector frees memory for objects that are no longer referenced, using generations (0, 1, 2) because most objects die young.
C# fundamentals
“Value types vs reference types?”
Value types (such as int, struct) hold their data directly and are copied on assignment. Reference types (such as class, string, arrays) hold a reference to data on the heap; assigning copies the reference, not the object.
“What’s the difference between IEnumerable<T> and IQueryable<T>?”
IEnumerable<T> runs queries in memory. IQueryable<T> builds an expression that a provider, such as Entity Framework Core, translates to SQL and runs on the database. Calling .ToList() too early on a query pulls all rows into memory.
“What is deferred execution in LINQ?”
A LINQ query doesn’t run when you define it, only when you enumerate it (for example with foreach, ToList() or Count()). Enumerating twice runs it twice.
“What do async and await do?”
They let a method wait for I/O (a database call, an HTTP request) without blocking a thread. In a web app, that frees threads to handle other requests. Avoid .Result and .Wait() on tasks, which block and can cause deadlocks in some contexts.
“What’s a record?”
A reference type (or record struct) designed for immutable data, with value-based equality and built-in with expressions for copies.
ASP.NET Core
“What is middleware?”
In Microsoft’s words: “Middleware is software that’s assembled into an app pipeline to handle requests and responses.” Each middleware “chooses whether to pass the request to the next middleware” and “can perform work before and after the next middleware in the pipeline.”
app.Use(async (context, next) =>
{
var start = DateTime.UtcNow;
await next(context); // call the rest of the pipeline
var ms = (DateTime.UtcNow - start).TotalMilliseconds;
app.Logger.LogInformation("{Path} took {Ms} ms", context.Request.Path, ms);
});
“Why does middleware order matter?”
Microsoft’s docs: the order that middleware appears in the Program file “defines the order in which middleware are invoked on a request with the reverse order for the response.” For example, authentication must run before authorization, and exception handling should come first so it can catch errors from everything after it.
“What does short-circuiting the pipeline mean?”
A middleware that doesn’t call next ends the request there. Static file middleware does this when it serves a file, which avoids unnecessary work.
“Explain the three dependency injection lifetimes.”
From Microsoft’s documentation:
- Transient: “created each time it’s requested from the service container.”
- Scoped: for web apps, “created once per client request (connection).”
- Singleton: created once, and every later request uses “the same instance.” Singletons must be thread-safe.
builder.Services.AddTransient<IEmailFormatter, EmailFormatter>();
builder.Services.AddScoped<IOrderService, OrderService>();
builder.Services.AddSingleton<IClock, SystemClock>();
“What’s the problem with injecting a scoped service into a singleton?”
The scoped service gets captured and lives as long as the singleton, which Microsoft warns “can lead to incorrect state when processing subsequent requests.” A DbContext is scoped by default, so this is a classic bug. If a singleton needs a scoped service, create a scope with IServiceScopeFactory. In development, ASP.NET Core’s scope validation throws an exception when this happens.
“How does configuration work?”
Configuration comes from several providers in order, such as appsettings.json, appsettings.{Environment}.json, environment variables, command-line arguments and secret stores, with later sources overriding earlier ones. Bind sections to typed classes with the options pattern (IOptions<T>, IOptionsSnapshot<T>, IOptionsMonitor<T>).
“Minimal APIs or controllers?”
Minimal APIs are concise and fast to set up, good for small services and simple endpoints. Controllers give more structure for large APIs with filters and conventions. Both run on the same routing and pipeline.
“What’s the difference between authentication and authorization?”
Authentication establishes who the user is (for example from a JWT or cookie); authorization decides what they’re allowed to do (roles, policies).
Classic ASP.NET vs ASP.NET Core
Many teams still maintain ASP.NET applications on .NET Framework, so interviews for those roles mix both.
“What’s the difference between ASP.NET and ASP.NET Core?”
Classic ASP.NET (4.x) runs on .NET Framework, on Windows and IIS, and is built on System.Web, with Web Forms, MVC 5 and Web API 2 as separate frameworks. Microsoft describes ASP.NET Core as “a cross-platform, high-performance, open-source framework for building modern web apps using .NET.” In practice: it runs on Windows, Linux and macOS, MVC and Web API are unified, dependency injection is built in, configuration comes from appsettings.json and environment variables instead of web.config, and a middleware pipeline replaces HTTP modules, handlers and Global.asax.
“What is Kestrel?”
ASP.NET Core’s built-in web server, which Microsoft calls “a high-performance and cross-platform HTTP server.” It can face the internet directly or sit behind a reverse proxy such as IIS, Nginx or a load balancer.
“MVC, Razor Pages or Blazor?”
MVC separates controllers, models and views and suits large apps and APIs. Razor Pages organizes code around pages and is simpler for page-focused apps such as forms. Blazor builds interactive web UI components in C# instead of JavaScript. The choice depends on how interactive the UI is and what the team knows.
“How do model binding and validation work?”
Model binding maps request data (route values, query strings, form fields and the JSON body) to action parameters and models. Validation runs data annotations such as [Required] and [Range], and the result is in ModelState; with [ApiController], invalid models automatically return a 400 response.
“What’s the difference between filters and middleware?”
Middleware runs for every request in the pipeline. Filters (authorization, resource, action, exception and result filters) run only around MVC or Razor Pages actions and have access to action context such as model binding results, which makes them right for cross-cutting concerns specific to endpoints.
“What was ViewState in Web Forms?”
Web Forms kept page and control state between postbacks in a hidden form field, which made stateful pages easy to build but pages heavy. ASP.NET Core has no ViewState; state lives in the client, the database, cache or session explicitly.
“How would you migrate an ASP.NET app to ASP.NET Core?”
Inventory dependencies on System.Web, Web Forms and Windows-only libraries, then migrate incrementally rather than in one big rewrite: move shared libraries to .NET Standard or modern .NET, migrate one area or endpoint group at a time behind a proxy, replace HTTP modules with middleware and web.config settings with configuration providers, and test each step.
Entity Framework Core
“What’s the N+1 problem, and how do you fix it?”
Loading a list and then running one extra query per item to load related data. Fix it with eager loading (Include), projection into a DTO with Select, or a split query.
“What does AsNoTracking() do?”
It returns entities that the context doesn’t track for changes, which is faster and uses less memory for read-only queries.
“How do you manage schema changes?”
With migrations: dotnet ef migrations add to create one, and apply them as part of deployment, ideally as a reviewed script rather than automatically at startup in production.
Performance and reliability
- How would you find a slow endpoint? Logs and traces first (for example with OpenTelemetry), then profiling. Check database queries before code.
- How do you cache? In-memory cache for single instances, a distributed cache such as Redis for multiple instances, with clear expiry rules.
- How do you handle transient failures when calling other services? Timeouts, retries with backoff and circuit breakers, for example with the resilience extensions for
HttpClient. - Why use
IHttpClientFactory? CreatingHttpClientinstances by hand can exhaust sockets or miss DNS changes; the factory manages handler lifetimes.
Testing
- Unit tests with xUnit, NUnit or MSTest, and mocks for dependencies.
- Integration tests with
WebApplicationFactory<TProgram>, which runs the app in memory. - Explain what you’d test and what you wouldn’t, not just the tool names.
Senior-level questions
- Design an order service that handles 1,000 requests per second. What would you cache, and what must be consistent?
- How would you split a monolith into services? What would you keep together?
- How do you make a background job safe to run twice?
- How do you roll out a breaking API change?
- Tell me about a production incident you led.
For these, talk through requirements, trade-offs and how you’d monitor the result. Behavioral questions still come up: see tell me about a time you solved a complex problem.
Frequently asked questions
What are the most common .NET Core interview questions?
What is the difference between ASP.NET and ASP.NET Core?
What are the three dependency injection lifetimes in .NET?
What is middleware in ASP.NET Core?
Which .NET version is current?
Is .NET Core the same as .NET?
Sources
- Microsoft, .NET and .NET Core Support Policy. Read on 30 September 2026.
- Microsoft Learn, Overview of ASP.NET Core. Read on 1 October 2026.
- Microsoft Learn, ASP.NET Core Middleware. Read on 30 September 2026.
- Microsoft Learn, Service lifetimes (dependency injection). Read on 30 September 2026.