How to change default view location scheme in ASP.NET MVC?

A simple solution would be to, in your Appication_Start get hold of the appropriate ViewEngine from the ViewEngines.Engines collection and update its ViewLocationFormats array and PartialViewLocationFormats. No hackery: it’s read/write by default. protected void Application_Start() { … // Allow looking up views in ~/Features/ directory var razorEngine = ViewEngines.Engines.OfType<RazorViewEngine>().First(); razorEngine.ViewLocationFormats = razorEngine.ViewLocationFormats.Concat(new string[] { “~/Features/{1}/{0}.cshtml” … Read more