Enable HTTP/3 in Azure WebApp running .NET6 on Linux

Tomas Hensrud Gulla 1 Reputation point
2022-05-29T10:58:57.707+00:00

I want to try HTTP/3 on my website running .NET6 in Azure.
How can I enable this on the WebApp?

Also, in my code - what portnumer should I put here for when the site in running in Azure?

.ConfigureKestrel((context, options) =>
{
options.ListenAnyIP(5001, listenOptions =>
{
listenOptions.Protocols = HttpProtocols.Http1AndHttp2AndHttp3;
listenOptions.UseHttps();
});
});

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,177 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Takahito Iwasa 4,851 Reputation points MVP
    2022-05-29T22:18:52.277+00:00

    Hi, @Tomas Hensrud Gulla

    You cannot enable it in Azure Web Apps.
    The App Service's internal load balancer needs to support HTTP/3, but it doesn't.

    If you want to use HTTP/3 with .NET 6 in Azure, you probably need to host it in a virtual machine at this point.

    Since Azure Load Balancer supports UDP, it may be used as an HTTP/3 load balancer.

    https://learn.microsoft.com/en-us/azure/load-balancer/concepts

    In .NET Core, the implementation is as follows.

    https://learn.microsoft.com/en-us/aspnet/core/fundamentals/servers/kestrel/http3?view=aspnetcore-6.0


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.