Get started with Blazor
Blazor is an unsupported experimental web framework that shouldn't be used for production workloads at this time.
- Install the .NET Core 2.1 SDK (2.1.302).
- Install Visual Studio 2017 (15.7 or later) with the ASP.NET and web development workload selected.
- Install the latest Blazor Language Services extension from the Visual Studio Marketplace.
To create your first project from Visual Studio:
- Select File > New Project > Web > ASP.NET Core Web Application.
- Make sure .NET Core and ASP.NET Core 2.1 (or later) are selected at the top.
Choose the Blazor template and select OK.
Press Ctrl-F5 to run the app without the debugger. Running with the debugger (F5) isn't supported at this time.
You can also install and use the Blazor templates from the command-line:
dotnet new -i Microsoft.AspNetCore.Blazor.Templates dotnet new blazor -o BlazorApp1 cd BlazorApp1 dotnet run
Congrats! You just ran your first Blazor app!
The default global.json file included in the Blazor project templates may cause the project to fail to load or run if you don't have version 2.1.3xx of the .NET Core SDK installed. The global.json file pins the project to 2.1.3xx; so if you don't have that specific version range installed, the project fails to load or run even if you have a newer SDK installed. The workaround is to remove the global.json file from the project or install version 2.1.302 of the .NET Core SDK.
Help & feedback
Your feedback is especially important to us during this experimental phase for Blazor. If you run into issues or have questions while trying out Blazor, please let us know!
- File issues on GitHub for any problems you run into or to make suggestions for improvements.
- Chat with us and the Blazor community on Gitter if you get stuck or to share how Blazor is working for you.
After you've tried out Blazor, please let us know what you think by taking our in-product survey. Just click the survey link shown on the app home page when running one of the Blazor project templates: