ASP.NET MVC, Web API Interview Questions with Answers


Hello everyone, this is the collection of most often asked, important and some tricky ASP .Net interview questions. This collection is totally based on interview experience. Moreover, count on me guys this collection is comprised of almost every IT company’s interview questions. Companies like TCS, Infosys, Wipro, HCL, Accenture, Deloitte, etc. are usually asking these questions. For the complete idea of interview procedure and common primary questions please visit this blog Full Stack Web Developer Interview.

Hints of some particular questions are provided in the brackets. All the questions are framed in a limited word format and concise structure. As a result, you quickly get the gist of the questions.

The use of this article is to quickly brush up your knowledge before you go for MVC Interviews. Just by reading these MVC interview questions does not mean you will go and clear MVC interviews. This article is last minute revision sheet before going for MVC interviews.

ASP.NET MVC Interview Questions

  1. What is the life cycle of MVC application? (pipeline)
  2. What are the types of Routing in ASP.NET MVC? (attribute, conventional)
  3. How controller works in MVC pipeline?
  4. What is base class of any action method?
  5. WebFroms vs MVC? (no http handlers like .aspx)
  6. How state management done in MVC?
  7. ViewData vs ViewBag vs TempData vs Session?
  8. How we can preserve data using TempData? (.keep function)
  9. How Polymorphism works in action methods? (action can return anything (action result)) (parameter overloading)
  10. What are Filters in MVC?
  11. What are Html Helpers?
  12. Explain Areas in MVC?
  13. What is Bundles in MVC and their Importance?
  14. Is it possible to create our own custom view engine using MVC?
  15. ViewState vs Hidden Fields in traditional ASP.NET
  16. What information Engine? Describe Razor Engine?

ASP.NET Web API interview Questions

  1. Life cycle of Web API?
  2. Advantages of using ASP.NET Web API?
  3. New features are introduced in ASP.NET Web API 2.0?
  4. Web API vs WCF?
  5. Can we return view from Web API? (No)
  6. What is Representational state transfer or REST?
  7. We have WCF restful API then why we need Web API?
  8. Difference and similarity between ASP.NET MVC and Web API?
  9. Asmx services vs simple HTTP binding?
  10. Security feature in Web API {Authorization and Authentication filters }
  11. Custom Authentication Filters?
  12. How Authentication and Authorization can be implemented in Web API?
  13. What logic used in filters?
  14. NET Identity?
  15. Bundling and Magnification?
  16. What are advantages of Bundling?
  17. If we combine 6 files in one bundle, then how many requests goes from client to server?
  18. What is the return type of Web API action result method? (json/xml)
  19. Can we declare “no action method” in a controller? (yes using data notation)
  20. Root for view or action?
  21. Where do we can do setting of user authorization detail? (router file)
  22. Where root table initialized? (App Start Method)
  23. How to manage sessions in ASP.NET Web API? (we can create JavaScript object and pass them on every request and then validate it)
  24. What kind of information there in APP_START Folder?

ASP.NET WCF interview Questions

  1. What is WCF?
  2. ABC of WCF?.
  3. Address in WCF?
  4. Binding in WCF ?
  5. Contracts in WCF?
  6. Transaction in WCF ?
  7. How transaction works in WCF?
  8. How many types of transport sachems are there in WCF?
  9. How many ways of hosting WCF services? (IIS, Self-Hosting, WAS (Windows Activation Service))
  10. Endpoint in WCF?