DataGrid / Columns / Show or Hide Column

Blazor DataGrid Example - Show or Hide Columns

Loading Syncfusion Blazor Server Demos…

Click the switch to toggle visibility
1 of 7 pages (75 items)

This sample demonstrates the DataGrid dynamic column visibility feature.

The Blazor DataGrid supports dynamic column visibility management through dedicated methods. Toggle column visibility by using the ShowColumnAsync and HideColumnAsync methods.

In this demo:

  • Click switch buttons to toggle column visibility dynamically
  • Columns are shown or hidden based on their HeaderText value
  • The visibility state changes immediately in the grid

To hide a column during initial DataGrid rendering, set the Visible property to false in the column definition.

This feature is useful for providing users with customizable grid views, allowing them to focus on the columns most relevant to their tasks.

For more detailed information about showing and hiding columns, refer to the show or hide columns documentation.

Transform your Blazor web apps today with Syncfusion® Blazor components
145+ high-performance and responsive UI components
Dedicated support
Hassle-free licensing
TRY IT FOR FREE