Assume we want to have an url to the Contacts page like mysite/Contacts instead of mysite/Home/Contacts
First of all open RouteConfig.cs under App_Start folder.
public static void RegisterRoutes(RouteCollection routes)
{
routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
routes.MapRoute("HomeRemover", "{action}/{id}", new { controller = "Home", action = "Index", id = UrlParameter.Optional }); // add this
routes.MapRoute("Home", "{controller}/{action}/{id}", new { controller = "Home", action = "Index", id = UrlParameter.Optional });
}
That's all.