Blazor wrong ssl certificate

Problem

When I try to run my blazor app, it shows "Your connection is not private" – wrong ssl certificate in browser.

file

file

Solution

Run in terminal/console:

Shell
dotnet dev-certs https --clean
dotnet dev-certs https --trust

Confirmation windows will pop-up, so confirm all of them and after this my blazor app runs just fine.