Library / SDK
dotnetcore/BootstrapBlazor avatar
dotnetcore/BootstrapBlazor

BootstrapBlazor: an enterprise Blazor UI library wired into Bootstrap

Bootstrap Blazor is an enterprise-level UI component library based on Bootstrap and Blazor.

4,911 stars391 forksC#Apache-2.0

At a glance

What is it?
BootstrapBlazor is a .NET Foundation component library that layers Bootstrap styling onto Blazor Server, WebAssembly and SSR. It ships a NuGet package plus a CLI template, and it expects you to register its services and root component before any control will render.
Who is it for?
Adopt BootstrapBlazor if your team already ships Bootstrap-styled .NET apps and wants Blazor components that inherit that look without a second design language, and if you are comfortable registering AddBootstrapBlazor() and wrapping your layout in BootstrapBlazorRoot. Do not adopt it if you want a component set with no Bootstrap dependency, or if your project is on a .NET version outside the net9 and net10 targets the repository topics list.
Can I use it commercially?
Yes. Apache-2.0 is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 1 day ago.
What is it written in?
Mainly C#, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 30, 2026, and from our analysis. They are not legal advice.

Editorial analysis

The gap BootstrapBlazor fills for Bootstrap-based .NET teams

Blazor gives you a component model and a rendering pipeline, but it does not give you a date picker, a data grid, a modal, or a tree. You either write those yourself or take a component library. The common choices in the .NET ecosystem tend to bring their own visual language, which means a team with an existing Bootstrap design system ends up maintaining two sets of CSS conventions.

BootstrapBlazor takes the opposite position. The README describes it as "an enterprise-level UI component library based on Bootstrap and Blazor," and the styling it ships is Bootstrap's. If your marketing site, your admin templates and your designers already speak in Bootstrap classes, the components drop into that vocabulary instead of competing with it. The audience is .NET teams building internal tools, dashboards and line-of-business apps where visual consistency with an existing Bootstrap front end matters more than having a distinctive component aesthetic.

The project is part of the .NET Foundation and operates under that foundation's code of conduct, which matters if your organisation has procurement rules about governance of dependencies. The licence is Apache-2.0.

How the component model is wired: root component, DI registration, static assets

BootstrapBlazor is not a drop-in stylesheet. Three separate things have to be in place before a component behaves correctly, and the README is explicit about each.

The first is a service registration. Components that need shared state, JavaScript interop coordination or lookup data resolve it from the DI container, so `builder.Services.AddBootstrapBlazor()` has to run during host startup. Skip it and you get resolution failures at render time rather than at compile time.

The second is a root component. The layout has to wrap its body in `<BootstrapBlazorRoot>`, which is where the library mounts the pieces that live outside the normal component tree: dialogs, toasts, tooltips and other overlays that cannot be rendered inline without breaking layout or stacking context. This is the structural decision that shapes the rest of the library. Overlay components are not self-contained; they depend on that ancestor existing.

The third is static assets. The bundle CSS and the bundle JavaScript are served from the package under `_content/BootstrapBlazor/`, which is the standard Razor class library asset path. Because the host model differs between WebAssembly, Server and a Razor Pages or MVC host, the README points you at `index.html` or `_Layout.cshtml`/`_Host.cshtml`/`App.razor` depending on which you are running. Getting this wrong is the most common way to end up with unstyled markup or components that render but do not respond to clicks.

Installing BootstrapBlazor and rendering your first component

The README's quick installation guide is short enough to follow literally. Start by adding the package to your Blazor project:

bash
dotnet add package BootstrapBlazor

Next, make the component namespace available without a per-file using. Add this to `_Imports.razor`:

razor
@using BootstrapBlazor.Components

Wrap the body of your main layout. In a default Blazor template that file is `MainLayout.razor`, and the README gives exactly this shape:

razor
<BootstrapBlazorRoot>
    @Body
</BootstrapBlazorRoot>

Add the bundle stylesheet to the head of your host page. Which file that is depends on your hosting model: `index.html` for WebAssembly, or `_Layout.cshtml`/`_Host.cshtml`/`App.razor` for the server-side and Razor Pages cases.

html
<link rel="stylesheet" href="_content/BootstrapBlazor/css/bootstrap.blazor.bundle.min.css" />

Add the matching script at the end of the body:

html
<script src="_content/BootstrapBlazor/js/bootstrap.blazor.bundle.min.js"></script>

Finally, register the services in `Program.cs`:

csharp
builder.Services.AddBootstrapBlazor();

With that in place, the README's usage example is a display field and a button. The button's click handler writes the current time into the text, which is enough to confirm that rendering, event dispatch and the JavaScript bundle are all working:

razor
<Display Value="@_text"></Display>
<Button Text="Button" OnClick="@ClickButton"></Button>

@code {
    private string? _text;
    private void ClickButton(MouseEventArgs e)
    {
        _text = DateTime.Now.ToString();
    }
}

If the button renders but the click does nothing, the script tag is the first thing to check. If it looks unstyled, the stylesheet link is.

There is also a project template. The README documents installing it and scaffolding a boilerplate app:

bash
dotnet new install Bootstrap.Blazor.Templates::*
dotnet new bbapp

That route is worth taking before wiring an existing project by hand, because the generated app already has the layout, asset links and service registration in the arrangement the library expects.

Where the design choices cost you

The root-component requirement is the constraint to weigh. Any overlay a component opens is mounted through `BootstrapBlazorRoot`, so a component used outside that subtree may compile and render inline while its dialogs or toasts never appear. In a large application with several layouts, or with components rendered into a separate render root, that is a real failure mode rather than a theoretical one.

The Bootstrap dependency is the second cost. If your team has moved to a utility framework or a CSS-in-component approach, BootstrapBlazor pulls Bootstrap's CSS back in, and reconciling the two is your problem. Choosing this library is partly a decision about your stylesheet, not just your component set.

The README does not document a rollback path for the bundle assets or a version-pinning strategy beyond what NuGet gives you, and it does not describe a theming or design-token layer. It also does not state which .NET versions the current package targets; the repository topics list `net9` and `net10`, and the environment section only says to install the .NET SDK and the latest Visual Studio. Treat the target framework as something to confirm against the package page rather than something the README settles.

Finally, the README's component documentation is thin. It shows a `Display` and a `Button`, and points elsewhere for the rest. For a grid, a chart or a modal you are relying on the online examples at blazor.zone and on the source, not on the README.

BootstrapBlazor compared with MudBlazor and Blazor Bootstrap

The two comparisons people search for most are against MudBlazor and against Blazor Bootstrap, and the difference in each case is about styling philosophy rather than component count.

MudBlazor implements Material Design. Its components look like Material components, and the design language is the library's own. That is an advantage if you have no existing design system, because you get a coherent look out of the box. It is a disadvantage if you already have a Bootstrap-based product, because now your admin screens and your public pages disagree about what a button looks like. BootstrapBlazor inverts that trade: it inherits Bootstrap's appearance, so it fits an existing Bootstrap front end, but it will not give you a distinctive visual identity you did not already have.

Blazor Bootstrap is the closer comparison, since both sit on Bootstrap and both target Blazor. They are separate projects with separate component sets, separate APIs and separate release cadences. Nothing in this repository's material describes how its component coverage compares with that project's, so the honest way to choose is to take the specific components you need (a data grid with server-side paging, a chart, a file upload) and check whether each library has them and what their parameters look like. The names being similar is not evidence that the APIs are interchangeable.

Maintenance, releases and what the licence lets you do

The repository is not archived. The last push was on 2026-09-22, one day before this was written, and the release history shows v10.10.1 on 2026-09-06, v10.10.0 on 2026-08-30 and v10.9.2 on 2026-08-13. That is a steady cadence of minor releases, and it tells you something practical: expect to move versions more than once a year, and expect the version numbers to be the thing you pin.

Upgrade cost is mostly the cost of a NuGet version bump plus whatever the changelog says. The repository carries `CHANGELOG.md` and `CHANGELOG.zh-CN.md` at the top level, so the record exists in-tree, and `Version.props` and `Directory.Build.props` show that versions are managed centrally rather than per-project. The README does not promise a support window or a long-term-support branch, so if you need one, that is a question for the maintainers rather than something you can read off the repository.

On licensing: the package is Apache-2.0. That is a permissive licence that generally allows commercial use, modification and redistribution, with conditions around notices and, in some readings, patent terms. It is not a copyleft licence. This is a description of the licence identifier, not legal advice; if your organisation has a licence review process, run the package through it rather than taking this paragraph as clearance.

Editorial conclusion

Adopt BootstrapBlazor if your team already ships Bootstrap-styled .NET apps and wants Blazor components that inherit that look without a second design language, and if you are comfortable registering AddBootstrapBlazor() and wrapping your layout in BootstrapBlazorRoot. Do not adopt it if you want a component set with no Bootstrap dependency, or if your project is on a .NET version outside the net9 and net10 targets the repository topics list. Before committing, verify three things: that your .NET SDK version matches the package target, that the bundle paths _content/BootstrapBlazor/css/bootstrap.blazor.bundle.min.css and _content/BootstrapBlazor/js/bootstrap.blazor.bundle.min.js resolve in your host model, and that the components you need exist in the version you pin.

Frequently asked questions

Is Blazor outdated?

Nothing in this repository's material addresses that question. What the repository does show is that Blazor is still receiving new component libraries and releases: BootstrapBlazor's most recent release is v10.10.1, published on 2026-09-06, with the last push to the repository on 2026-09-22.

Which is better, WPF or Blazor?

The repository does not compare the two. BootstrapBlazor is a Blazor component library only, and it targets Blazor hosting models such as WebAssembly and Server, so it has no bearing on a WPF desktop application.

Is Blazor better than React?

The repository takes no position on this. BootstrapBlazor is built on Bootstrap and Blazor, and the styling it ships is Bootstrap's, so a team already using Bootstrap can reuse that vocabulary rather than adopt a second design language.

Which Blazor UI library is the best?

This repository does not rank libraries. BootstrapBlazor's own position is that it is an enterprise-level UI component library based on Bootstrap and Blazor, and its practical constraint is that the layout must wrap its body in `<BootstrapBlazorRoot>` for overlay components to mount.

Official sources

  1. dotnetcore/BootstrapBlazor on GitHub
  2. License: Apache-2.0
  3. Project website
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/dotnetcore-bootstrapblazor.svg)](https://hysenlabs.com/projects/dotnetcore-bootstrapblazor)