Evaluate the Grid SDK free.Start building today.
Add the Grid SDK to your app.
Use a package manager to add the Grid SDK to your application now, or download Syncfusion Studio to browse samples and binaries on your desktop.
Follow these steps to integrate the Blazor DataGrid component into an existing Blazor Web App using the Interactive Server render mode.
Install NuGet Packages
Open the Package Manager Console (PMC) in Visual Studio or the integrated terminal in VS Code, and run the corresponding command for your IDE.
Install-Package Syncfusion.Blazor.Grid Install-Package Syncfusion.Blazor.Themes
dotnet add package Syncfusion.Blazor.Grid dotnet add package Syncfusion.Blazor.Themes
Register Syncfusion Blazor Service
Register the Syncfusion Blazor service in the Program.cs file after the builder instance is created (the using Syncfusion.Blazor; directive is auto-resolved by the framework).
builder.Services.AddSyncfusionBlazor();
Register Syncfusion license key
Register the Syncfusion license key in the Program.cs file after the AddSyncfusionBlazor() call.
// Register Syncfusion license key
Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("YOUR_LICENSE_KEY");
Add Theme Stylesheet and Script
Add the Syncfusion theme stylesheet at the end of the <head> section in the Components/App.razor file to apply styling.
<link href="_content/Syncfusion.Blazor.Themes/fluent2.css" rel="stylesheet" />
Add Syncfusion Blazor DataGrid component
Add the Syncfusion Blazor DataGrid component in ~/Components/Pages/Home.razor.
@rendermode InteractiveServer
@using Syncfusion.Blazor.Grids
<SfGrid DataSource="@OrderData">
<GridColumns>
<GridColumn Field=@nameof(OrderDetails.OrderID) HeaderText="Order ID" TextAlign="TextAlign.Right" Width="120"></GridColumn>
<GridColumn Field=@nameof(OrderDetails.CustomerID) HeaderText="Customer Name" Width="120"></GridColumn>
<GridColumn Field=@nameof(OrderDetails.Freight) HeaderText="Freight" Format="C2" TextAlign="TextAlign.Right" EditType="EditType.NumericEdit" Width="120"></GridColumn>
<GridColumn Field=@nameof(OrderDetails.ShipCountry) HeaderText="Ship Country" EditType="EditType.DropDownEdit" Width="150"></GridColumn>
</GridColumns>
</SfGrid>
@code {
public List<OrderDetails>? OrderData { get; set; }
protected override void OnInitialized()
{
OrderData = OrderDetails.GetAllRecords();
}
public class OrderDetails
{
public static List<OrderDetails> Order = new List<OrderDetails>();
public OrderDetails(int OrderID, string CustomerId, double Freight, string ShipCountry)
{
this.OrderID = OrderID;
this.CustomerID = CustomerId;
this.Freight = Freight;
this.ShipCountry = ShipCountry;
}
public static List<OrderDetails> GetAllRecords()
{
if (Order.Count == 0)
{
Order.Add(new OrderDetails(10248, "VINET", 32.38, "France"));
Order.Add(new OrderDetails(10249, "TOMSP", 11.61, "Germany"));
Order.Add(new OrderDetails(10250, "HANAR", 65.83, "Brazil"));
Order.Add(new OrderDetails(10251, "VICTE", 41.34, "France"));
Order.Add(new OrderDetails(10252, "SUPRD", 51.3, "Belgium"));
}
return Order;
}
public int OrderID { get; set; }
public string CustomerID { get; set; }
public double Freight { get; set; }
public string ShipCountry { get; set; }
}
}
Search a control. Copy its install command.
Search 245 controls across 14 platforms. Each command comes from that control’s getting-started guide, and every package is checked on NuGet, npm, or pub.dev.
Loading controls…
Evaluate faster with your coding agent.
Paste this prompt into GitHub Copilot, Claude Code, Cursor, or any agent. It sets up Syncfusion for your project from ai.syncfusion.com before it writes code.
Set up this project for Syncfusion before generating code. Fetch and follow the official instructions at https://ai.syncfusion.com then report the detected platform, installed skills, MCP status, and any required licensing action.
No key needed to install the skills. The MCP servers use the API key that comes with a free account. Agent setup guides
AI assistants
IDEs
Short, task-first walkthroughs.
Need help getting started?
Explore our resources or reach out to our support team for assistance.
Product Updates
Technical Support
AI Solutions
Syncfusion Studio for your desktop.
One small download. Browse every product, download samples and binaries, and set up your IDE and AI assistant.