For ASP.NET Core:
Add one of the following lines to the ConfigureServices method of the Startup class:
services.AddRouting(options => options.LowercaseUrls = true);
or
services.Configure<RouteOptions>(options => options.LowercaseUrls = true);
Thanks to Skorunka for the answer as a comment. I thought it was worth promoting to an actual answer.