{"id":3887,"date":"2025-05-28T18:00:53","date_gmt":"2025-05-28T16:00:53","guid":{"rendered":"https:\/\/uniquedevs.com\/blog\/tanstack-table-elastyczne-i-potezne-tabele-w-react\/"},"modified":"2025-06-04T18:04:18","modified_gmt":"2025-06-04T16:04:18","slug":"tanstack-table-flexible-and-powerful-tables-in-react","status":"publish","type":"post","link":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/","title":{"rendered":"TanStack Table &#8211; flexible and powerful tables in React"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">What is the TanStack Table?<\/h2>\n\n\n\n<p>TanStack Table (formerly known as React Table) is an advanced <a href=\"https:\/\/uniquedevs.com\/en\/blog\/javascript-explained-a-deep-dive-into-the-webs-core-language\/\">JavaScript <\/a>library for building dynamic, fully customizable tables and data grids (data grids). Its biggest differentiator is that it runs on a <strong>headless UI<\/strong> model &#8211; meaning that it provides only logic, state management and interaction tools, without imposing <a href=\"https:\/\/uniquedevs.com\/en\/blog\/html-the-foundation-of-websites\/\">HTML<\/a> structure or CSS styles.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Headless UI &#8211; what does it actually mean?<\/h3>\n\n\n\n<p>Traditional component libraries (e.g. AG Grid or Material UI Table) offer ready-made components with imposed structure and appearance. This works well, as long as you don&#8217;t need full control over the look or integration with your own design system. TanStack Table goes in the opposite direction: it lets you completely decide how your table looks and behaves &#8211; while taking responsibility for the hardest parts: state management, data processing, sorting, filtering or pagination.<\/p>\n\n\n\n<p>In practice, this means that TanStack Table does not render anything for you. Instead, it gives you access to ready-made logic that you can embed in your components as you see fit. This allows you to create tables:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>with your own HTML tags or UI components,<\/li>\n\n\n\n<li>styled using\u00a0<a href=\"https:\/\/uniquedevs.com\/en\/blog\/basic-guide-to-tailwind-css\/\">TailwindCSS<\/a>, Styled Components, CSS-in-JS, or any other method,<\/li>\n\n\n\n<li>which are fully accessible (a11y) and optimized for performance.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Framework-agnostic philosophy<\/h3>\n\n\n\n<p>Although TanStack Table started life as a library strictly for&nbsp;<a href=\"https:\/\/uniquedevs.com\/en\/blog\/react-js-basics\/\">React<\/a>, today it also supports other frontend frameworks such as Vue, Svelte, Solid, and Qwik. This makes it a future-proof solution \u2013 no matter what technology you choose for your next project, TanStack Table&#8217;s approach and API will remain familiar.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">When should you use TanStack Table in your project?<\/h2>\n\n\n\n<p>TanStack Table is particularly useful when:<\/p>\n\n\n\n<p>&#8211; You want full control over the appearance of the table: whether you use Tailwind, MUI, Chakra UI, or your own styling system, TanStack Table imposes no restrictions. You decide on the HTML and CSS structure.<\/p>\n\n\n\n<p>&#8211; you are integrating with a non-standard design system (Design System). Do you have a corporate design system or do you need to strictly adhere to client guidelines? TanStack Table will fit right in, as it does not enforce any predefined styles or components.<\/p>\n\n\n\n<p>&#8211; Need efficient handling of large data sets? Thanks to virtualization support and intelligent state management, the library can handle tables with thousands of rows without slowing down the interface.<\/p>\n\n\n\n<p>-Do you require flexibility when implementing complex interactive features: data grouping, expandable rows, drag-and-drop columns, custom cell editors? You can build all of this on top of TanStack Table&#8217;s logic \u2013 without compromise.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Examples of TanStack Table&#8217;s most important features<\/h2>\n\n\n\n<p>TanStack Table is a library that does not provide ready-made components \u2013 but it gives you all the tools you need to build exactly the table you need. Below you will find key features with practical examples of their use in React.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">1. Data sorting<\/h3>\n\n\n\n<p>Sorting is one of the most common functions in a table. In TanStack Table, you can easily enable column sorting. Example:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>import {\n  useReactTable,\n  getCoreRowModel,\n  getSortedRowModel,\n} from '@tanstack\/react-table'\n\nconst table = useReactTable({\n  data,\n  columns,\n  state: {\n    sorting,\n  },\n  onSortingChange: setSorting,\n  getCoreRowModel: getCoreRowModel(),\n  getSortedRowModel: getSortedRowModel(),\n})\n<\/code><\/pre>\n\n\n\n<p>Just click on the column header to change the sort order. You can also create your own sort icons and logic for data types (e.g., dates, numbers, text).<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">2. Data filtering<\/h3>\n\n\n\n<p>You can add both global filtering and individual column filtering \u2013 all with your own UI. Below is an example of text filtering for a column:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>{\n  accessorKey: 'email',\n  header: 'Email',\n  filterFn: 'includesString',\n}\n<\/code><\/pre>\n\n\n\n<p>Custom filter field component:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;input\n  value={table.getColumn('email')?.getFilterValue() ?? ''}\n  onChange={(e) =&gt;\n    table.getColumn('email')?.setFilterValue(e.target.value)\n  }\n\/&gt;\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">3. Pagination<\/h3>\n\n\n\n<p>TanStack Table supports both local and server-based paging &#8211; depending on your data source. Example (local):<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>const table = useReactTable({\n  pageCount: -1, \/\/ \n  manualPagination: true,\n  onPaginationChange: setPagination,\n  getPaginationRowModel: getPaginationRowModel(),\n})\n<\/code><\/pre>\n\n\n\n<p>Pages, counter, &#8220;next\/previous&#8221; &#8211; you can implement any interface you want.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">4. Data grouping<\/h3>\n\n\n\n<p>You can group rows by one or more columns, creating a nested data structure. Example:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>{\n  accessorKey: 'department',\n  enableGrouping: true,\n}\n<\/code><\/pre>\n\n\n\n<p>The result: data is grouped by <code>department<\/code>, and each group can be expanded\/closed dynamically.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">5. Data aggregation<\/h3>\n\n\n\n<p>Aggregation is an extremely useful feature, especially in the context of analytical, financial, or reporting applications. It allows you to automatically summarize values in columns\u2014for example, calculate total sales, average rating, number of reports, or maximum value.<\/p>\n\n\n\n<p>TanStack Table allows you to assign your own aggregation function to a column (e.g.,&nbsp;<code>sum<\/code>,&nbsp;<code>average<\/code>,&nbsp;<code>count<\/code>,&nbsp;<code>max<\/code>,&nbsp;<code>min<\/code>, or a completely custom function) and define how a given column should behave in a group row.<\/p>\n\n\n\n<p>Below is an example of summing salaries by department:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>{\n  accessorKey: 'salary',\n  header: 'Salary',\n  aggregationFn: 'sum', \/\/ aggregation function\n  aggregatedCell: ({ getValue }) => `Suma: $${getValue()}`, \/\/ group row view\n}\n<\/code><\/pre>\n\n\n\n<p>In combination with the grouping feature, TanStack Table will automatically sum all&nbsp;<code>salary<\/code>&nbsp;values for each&nbsp;<code>department<\/code>and display the summary in the group. Why is this important? Because it makes it easy to present aggregate data without additional server-side logic. You can easily extend the table UI with summary rows, section summaries, or even multi-level aggregates. In addition, you have full control over the presentation format of aggregated data \u2013 you can highlight it graphically, color it, add icons, etc.<\/p>\n\n\n\n<p>This feature works particularly well in dashboards, reports, online spreadsheets, and ERP\/CRM systems.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">6. Virtualization<\/h3>\n\n\n\n<p>If your table contains thousands of rows, you can use&nbsp;<code>@tanstack\/react-virtual<\/code>to render only the visible elements, significantly improving performance. For example, instead of rendering 10,000 rows, only the 30 currently visible rows are rendered.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">7. Column customization<\/h3>\n\n\n\n<p>One of the biggest advantages of TanStack Table is that it gives you complete freedom to define, modify, and manage columns \u2013 both during table configuration and dynamically during application runtime. This is extremely useful in projects where the interface needs to adapt to user roles, preferences, or business context. Below we show dynamic columns based on a condition:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>const userColumns = showSalary\n  ? &#91;...baseColumns, salaryColumn]\n  : baseColumns\n<\/code><\/pre>\n\n\n\n<p>In this example, the &#8220;salary&#8221; column will only be visible if <code>showSalary<\/code> returns <code>true<\/code> &#8211; for example, if the user has permission to see salary data.<\/p>\n\n\n\n<p>What can you do with column personalization? E.g.: based on application status, user role or filter, you can hide or show a column. You can let users drag (drag-and-drop) columns to rearrange the table according to their preferences. What else? You can save your column configuration (e.g., visibility, width, order) to a localStorage, database or user profile &#8211; and restore it with each session. Here&#8217;s an example: setting custom headers and widths:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>{\n  accessorKey: 'createdAt',\n  header: () => &lt;span>Date of creation&lt;\/span>,\n  size: 180,\n}\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">8. Styling and integration with UI systems<\/h3>\n\n\n\n<p>TanStack Table stands out because it does not impose any styling or HTML structure on you. Unlike ready-made components from libraries such as Material UI or Bootstrap, TanStack Table allows you to define every element of the table yourself: from&nbsp;<code>&lt;table&gt;<\/code>, through&nbsp;<code>&lt;thead&gt;<\/code>&nbsp;and&nbsp;<code>&lt;tbody&gt;<\/code>, to cells, sorting buttons, pagination, and even loading spinners.<\/p>\n\n\n\n<p>This approach gives you complete freedom to integrate with any UI design system \u2013 no friction, no rework, no fighting with style overrides.<\/p>\n\n\n\n<p>TailwindCSS works great with TanStack Table. Thanks to utility classes, you can style every table element with precision without the need to create additional components. For example:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;table className=\"min-w-full divide-y divide-gray-200\"&gt;\n  &lt;thead className=\"bg-gray-50\"&gt;\n    &lt;tr&gt;\n      {table.getHeaderGroups().map(headerGroup =&gt;\n        headerGroup.headers.map(header =&gt; (\n          &lt;th\n            className=\"px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider\"\n            key={header.id}\n          &gt;\n            {header.column.columnDef.header}\n          &lt;\/th&gt;\n        ))\n      )}\n    &lt;\/tr&gt;\n  &lt;\/thead&gt;\n&lt;\/table&gt;\n<\/code><\/pre>\n\n\n\n<p>In the example above, the table headers are fully controlled and styled using Tailwind \u2013 but you could just as easily use your own CSS classes or any other styling system. Regardless of how you style your application, TanStack Table supportsany custom components with rendering logic: TailwindCSS, CSS Modules, Styled Components \/ Emotion, Vanilla CSS, UI frameworks (MUI, Chakra, Bootstrap).<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Creating your first table with TanStack Table<\/h2>\n\n\n\n<p>To see for yourself how amazing TanStack Table is, we recommend that you start your first project. In a few steps, we will show you how to create your first table.<\/p>\n\n\n\n<p>1. Install the necessary packages:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>npm install @tanstack\/react-table\n<\/code><\/pre>\n\n\n\n<p>If you plan to handle large data sets and are concerned about performance, it&#8217;s also worth adding virtualization:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>npm install @tanstack\/react-virtual\n<\/code><\/pre>\n\n\n\n<p class=\"language-markup\">2. Create a basic table &#8211; suppose you have user data. Let&#8217;s start with data and column definitions:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>const data = &#91;\n  { id: 1, name: 'Anna', email: 'anna@example.com' },\n  { id: 2, name: 'Tom', email: 'tomasz@example.com' },\n]\n\nconst columns = &#91;\n  {\n    accessorKey: 'name',\n    header: 'Name',\n  },\n  {\n    accessorKey: 'email',\n    header: 'Email',\n  },\n]\n<\/code><\/pre>\n\n\n\n<p>Next, we initialize the table:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>import { useReactTable, getCoreRowModel } from '@tanstack\/react-table'\n\nconst table = useReactTable({\n  data,\n  columns,\n  getCoreRowModel: getCoreRowModel(),\n})\n<\/code><\/pre>\n\n\n\n<p>Now we are rendering the table:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;table>\n  &lt;thead>\n    {table.getHeaderGroups().map(headerGroup => (\n      &lt;tr key={headerGroup.id}>\n        {headerGroup.headers.map(header => (\n          &lt;th key={header.id}>\n            {\/*  Use flexRender, if you want to render custom components or JSX *\/}\n            {header.isPlaceholder\n              ? null\n              : flexRender(\n                  header.column.columnDef.header,\n                  header.getContext()\n                )}\n          &lt;\/th>\n        ))}\n      &lt;\/tr>\n    ))}\n  &lt;\/thead>\n  &lt;tbody>\n    {table.getRowModel().rows.map(row => (\n      &lt;tr key={row.id}>\n        {row.getVisibleCells().map(cell => (\n          &lt;td key={cell.id}>\n            {\/* \ud83e\udde0 To samo dotyczy kom\u00f3rek danych \u2013 flexRender obs\u0142u\u017cy komponenty, JSX, tekst, liczby itd. *\/}\n            {flexRender(\n              cell.column.columnDef.cell,\n              cell.getContext()\n            )}\n          &lt;\/td>\n        ))}\n      &lt;\/tr>\n    ))}\n  &lt;\/tbody>\n&lt;\/table>\n\n<\/code><\/pre>\n\n\n\n<p>Use <code>flexRender<\/code> instead of a direct call to <code>.renderCell()<\/code>. <code>flexRender()<\/code> is a function created by the authors of TanStack Table that supports both simple values (e.g. string, number) and JSX rendering functions. With it, you can use e.g. <code>() => &lt;span>{value}&lt;\/span><\/code> in columns without the risk that the table will return <code>[Object Object]<\/code> or nothing.<\/p>\n\n\n\n<p>Each <code>header<\/code> and <code>cell<\/code> can be a rendering function. In column definition, you can use functions in <code>header<\/code> and <code>cell<\/code>, for example:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>{\n  accessorKey: 'email',\n  header: () =&gt; &lt;span&gt;Email \ud83d\udce7&lt;\/span&gt;,\n  cell: ({ getValue }) =&gt; (\n    &lt;a href={`mailto:${getValue()}`} className=\"text-blue-600 underline\"&gt;\n      {getValue()}\n    &lt;\/a&gt;\n  )\n}\n<\/code><\/pre>\n\n\n\n<p>Then we move on to point 3, which is to add extensions to the logic:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>import {\n  getSortedRowModel,\n  getFilteredRowModel,\n  getPaginationRowModel,\n} from '@tanstack\/react-table'\n\nconst table = useReactTable({\n  data,\n  columns,\n  state: {\n    sorting,\n    pagination,\n    columnFilters,\n  },\n  onSortingChange: setSorting,\n  onPaginationChange: setPagination,\n  onColumnFiltersChange: setColumnFilters,\n  getCoreRowModel: getCoreRowModel(),\n  getSortedRowModel: getSortedRowModel(),\n  getFilteredRowModel: getFilteredRowModel(),\n  getPaginationRowModel: getPaginationRowModel(),\n})\n<\/code><\/pre>\n\n\n\n<p>Add a UI for sorting (e.g., click on the header):<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;th\n  onClick={header.column.getToggleSortingHandler()}\n&gt;\n  {header.column.columnDef.header}\n  {header.column.getIsSorted() === 'asc' ? ' \ud83d\udd3c' : ' \ud83d\udd3d'}\n&lt;\/th&gt;\n<\/code><\/pre>\n\n\n\n<p>Then we add a simple filter:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;input\n  value={table.getColumn('name')?.getFilterValue() ?? ''}\n  onChange={e =&gt;\n    table.getColumn('name')?.setFilterValue(e.target.value)\n  }\n\/&gt;\n<\/code><\/pre>\n\n\n\n<p>and pagination buttons:<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;button onClick={() => table.previousPage()} disabled={!table.getCanPreviousPage()}>\n  Previous\n&lt;\/button>\n&lt;button onClick={() => table.nextPage()} disabled={!table.getCanNextPage()}>\n  next\n&lt;\/button>\n<\/code><\/pre>\n\n\n\n<p>4. Customize the table appearance. Here, you have complete freedom. You can use Tailwind, Styled Components, MUI, or classic CSS. Below is an example using Tailwind CSS.<\/p>\n\n\n\n<pre class=\"wp-block-code language-markup\"><code>&lt;table className=\"min-w-full table-auto border border-gray-200\"&gt;\n  &lt;thead className=\"bg-gray-100\"&gt;\n    &lt;tr&gt;\n      {table.getHeaderGroups().map(headerGroup =&gt; (\n        headerGroup.headers.map(header =&gt; (\n          &lt;th\n            key={header.id}\n            className=\"px-4 py-2 text-left font-semibold text-sm text-gray-600\"\n          &gt;\n            {header.column.columnDef.header}\n          &lt;\/th&gt;\n        ))\n      ))}\n    &lt;\/tr&gt;\n  &lt;\/thead&gt;\n&lt;\/table&gt;\n<\/code><\/pre>\n\n\n\n<p>Congratulations! You have just created your first fully functional table using TanStack Table &#8211; with custom data, sorting, filtering and pagination. From now on, you have a foundation on which to build more advanced and customized solutions for your project.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Summary<\/h2>\n\n\n\n<p><strong>TanStack Table<\/strong>&nbsp;is a tool that perfectly meets the needs of modern frontend teams: it offers maximum flexibility, full control, and tremendous scalability\u2014without imposing any stylistic or architectural constraints.<\/p>\n\n\n\n<p>Unlike ready-made component libraries, which often offer a lot but come with difficult-to-work-around limitations, TanStack Table works in a \u201cheadless-first\u201d spirit. This means that everything you see in the interface \u2013 style, markup, interactions \u2013 is created by you, and the library is only responsible for the really difficult stuff: logic, state, performance, and data processing.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">FAQ \u2013 Frequently asked questions about TanStack Table<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">1.&nbsp;<strong>How is TanStack Table different from component libraries (e.g., AG Grid, MUI Table)?<\/strong><\/h3>\n\n\n\n<p>TanStack Table is a&nbsp;<em>headless UI<\/em>&nbsp;library \u2013 it does not provide ready-made components or styles. Instead, it gives you the full table management logic (sorting, filtering, pagination, grouping, etc.), and you create the look and HTML structure yourself. This is ideal when you want full control over the user interface.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">2.&nbsp;<strong>Does TanStack Table only work with React?<\/strong><\/h3>\n\n\n\n<p>No! Although it is most commonly used in React projects, TanStack Table also supports other frontend frameworks such as Vue, Svelte, Solid, and Qwik. Each version has a dedicated API tailored to the specifics of the framework.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">3. Do I need additional libraries to run TanStack Table?<\/h3>\n\n\n\n<p>No,&nbsp;<code>@tanstack\/react-table<\/code>is all you need to get started. If you care about performance with large data sets, you can install&nbsp;<code>@tanstack\/react-virtual<\/code>, which enables virtualization (rendering only visible rows).<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">4.&nbsp;<strong>Can I use TanStack Table with TailwindCSS, MUI, or my own design system?<\/strong><\/h3>\n\n\n\n<p>Yes, and that&#8217;s its biggest advantage. TanStack Table doesn&#8217;t impose any styling, which means you can freely integrate it with any CSS system: Tailwind, Styled Components, Emotion, Material UI, Bootstrap \u2013 even your own design system.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">5.&nbsp;<strong>Is TanStack Table suitable for large production projects?<\/strong><\/h3>\n\n\n\n<p>Absolutely. It is a mature, stable, and highly performant library used in many professional applications. Thanks to its modularity, light weight, and flexible API, it works great in large systems: from admin panels to analytics apps to advanced B2B tools.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Creating advanced tables in web applications is one of those tasks that on the surface seems simple &#8211; until the user expects sorting, filtering, pagination, grouping, flexible styling and performance with thousands of rows of data. Then it turns out that classic table components can&#8217;t keep up with design and business needs.<br \/>\nIn this article, I&#8217;ll show you what TanStack Table is, how the headless approach works, how it differs from traditional component libraries, and how to create a fully functional yet customized table with its help, step by step. Whether you are developing an analytics dashboard, CMS system or business application, TanStack Table can become one of your most important tools.<\/p>\n","protected":false},"author":2,"featured_media":4832,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[17],"tags":[],"class_list":["post-3887","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-front-end"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>TanStack Table - flexible and powerful tables in React<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"TanStack Table - flexible and powerful tables in React\" \/>\n<meta property=\"og:description\" content=\"Creating advanced tables in web applications is one of those tasks that on the surface seems simple - until the user expects sorting, filtering, pagination, grouping, flexible styling and performance with thousands of rows of data. Then it turns out that classic table components can&#039;t keep up with design and business needs. In this article, I&#039;ll show you what TanStack Table is, how the headless approach works, how it differs from traditional component libraries, and how to create a fully functional yet customized table with its help, step by step. Whether you are developing an analytics dashboard, CMS system or business application, TanStack Table can become one of your most important tools.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/\" \/>\n<meta property=\"og:site_name\" content=\"Software House - rozwi\u0105zania IT dla Twojego biznesu | UniqueDevs\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/people\/Unique-Devs\/61564365418277\/\" \/>\n<meta property=\"article:published_time\" content=\"2025-05-28T16:00:53+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-06-04T16:04:18+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp\" \/>\n\t<meta property=\"og:image:width\" content=\"853\" \/>\n\t<meta property=\"og:image:height\" content=\"1280\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/webp\" \/>\n<meta name=\"author\" content=\"Hubert Olech\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Hubert Olech\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"11 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/\"},\"author\":{\"name\":\"Hubert Olech\",\"@id\":\"https:\/\/uniquedevs.com\/#\/schema\/person\/a2c9b776ac544a910615b03c8b9c4c18\"},\"headline\":\"TanStack Table &#8211; flexible and powerful tables in React\",\"datePublished\":\"2025-05-28T16:00:53+00:00\",\"dateModified\":\"2025-06-04T16:04:18+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/\"},\"wordCount\":1763,\"publisher\":{\"@id\":\"https:\/\/uniquedevs.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp\",\"articleSection\":[\"Front-end\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/\",\"url\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/\",\"name\":\"TanStack Table - flexible and powerful tables in React\",\"isPartOf\":{\"@id\":\"https:\/\/uniquedevs.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp\",\"datePublished\":\"2025-05-28T16:00:53+00:00\",\"dateModified\":\"2025-06-04T16:04:18+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage\",\"url\":\"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp\",\"contentUrl\":\"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp\",\"width\":853,\"height\":1280},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Strona g\u0142\u00f3wna\",\"item\":\"https:\/\/uniquedevs.com\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Front-end\",\"item\":\"https:\/\/uniquedevs.com\/blog\/category\/front-end\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"TanStack Table &#8211; flexible and powerful tables in React\"}]},{\"@type\":\"Website\",\"@id\":\"https:\/\/uniquedevs.com\/#website\",\"url\":\"https:\/\/uniquedevs.com\/\",\"name\":\"Software House - rozwi\u0105zania IT dla Twojego biznesu | UniqueDevs\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/uniquedevs.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/uniquedevs.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},[],{\"@type\":\"Person\",\"@id\":\"https:\/\/uniquedevs.com\/#\/schema\/person\/a2c9b776ac544a910615b03c8b9c4c18\",\"name\":\"Hubert Olech\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/uniquedevs.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/uniquedevs.com\/wp-content\/litespeed\/avatar\/4aa41b6b162ba5c7c2dc5577af43de87.jpg?ver=1776685844\",\"contentUrl\":\"https:\/\/uniquedevs.com\/wp-content\/litespeed\/avatar\/4aa41b6b162ba5c7c2dc5577af43de87.jpg?ver=1776685844\",\"caption\":\"Hubert Olech\"},\"description\":\"Huber Olech - Founder @UniqueDevs. \u0141\u0105cz\u0119 \u015bwiat technologii z biznesem, pomagaj\u0105c firmom rozwija\u0107 si\u0119 dzi\u0119ki innowacyjnym rozwi\u0105zaniom cyfrowym. Pasja do software development zainspirowa\u0142a mnie do zbudowania zespo\u0142u ekspert\u00f3w, z kt\u00f3rymi wsp\u00f3lnie dostarczamy najwy\u017cszej jako\u015bci produkty dla swoich Klient\u00f3w. W oparciu o swoje wieloletnie do\u015bwiadczenie w bran\u017cy IT, rozumiem trendy w nowych technologiach i potrafi\u0119 przeku\u0107 je w wymierne korzy\u015bci dla firm. Moj\u0105 misj\u0105 jest tworzenie rozwi\u0105za\u0144, kt\u00f3re nie tylko usprawniaj\u0105 procesy, ale tak\u017ce otwieraj\u0105 przed Klientami nowe mo\u017cliwo\u015bci rynkowe i zwi\u0119kszaj\u0105 ich konkurencyjno\u015b\u0107.\",\"sameAs\":[\"https:\/\/www.linkedin.com\/in\/hubert-olech-b0a524167\/\"],\"url\":\"https:\/\/uniquedevs.com\/en\/blog\/author\/h-olech\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"TanStack Table - flexible and powerful tables in React","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"og_locale":"en_US","og_type":"article","og_title":"TanStack Table - flexible and powerful tables in React","og_description":"Creating advanced tables in web applications is one of those tasks that on the surface seems simple - until the user expects sorting, filtering, pagination, grouping, flexible styling and performance with thousands of rows of data. Then it turns out that classic table components can't keep up with design and business needs. In this article, I'll show you what TanStack Table is, how the headless approach works, how it differs from traditional component libraries, and how to create a fully functional yet customized table with its help, step by step. Whether you are developing an analytics dashboard, CMS system or business application, TanStack Table can become one of your most important tools.","og_url":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/","og_site_name":"Software House - rozwi\u0105zania IT dla Twojego biznesu | UniqueDevs","article_publisher":"https:\/\/www.facebook.com\/people\/Unique-Devs\/61564365418277\/","article_published_time":"2025-05-28T16:00:53+00:00","article_modified_time":"2025-06-04T16:04:18+00:00","og_image":[{"width":853,"height":1280,"url":"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp","type":"image\/webp"}],"author":"Hubert Olech","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Hubert Olech","Est. reading time":"11 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#article","isPartOf":{"@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/"},"author":{"name":"Hubert Olech","@id":"https:\/\/uniquedevs.com\/#\/schema\/person\/a2c9b776ac544a910615b03c8b9c4c18"},"headline":"TanStack Table &#8211; flexible and powerful tables in React","datePublished":"2025-05-28T16:00:53+00:00","dateModified":"2025-06-04T16:04:18+00:00","mainEntityOfPage":{"@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/"},"wordCount":1763,"publisher":{"@id":"https:\/\/uniquedevs.com\/#organization"},"image":{"@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage"},"thumbnailUrl":"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp","articleSection":["Front-end"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/","url":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/","name":"TanStack Table - flexible and powerful tables in React","isPartOf":{"@id":"https:\/\/uniquedevs.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage"},"image":{"@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage"},"thumbnailUrl":"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp","datePublished":"2025-05-28T16:00:53+00:00","dateModified":"2025-06-04T16:04:18+00:00","breadcrumb":{"@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#primaryimage","url":"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp","contentUrl":"https:\/\/uniquedevs.com\/wp-content\/uploads\/2025\/05\/code-3622942_1280.webp","width":853,"height":1280},{"@type":"BreadcrumbList","@id":"https:\/\/uniquedevs.com\/en\/blog\/tanstack-table-flexible-and-powerful-tables-in-react\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Strona g\u0142\u00f3wna","item":"https:\/\/uniquedevs.com\/en\/"},{"@type":"ListItem","position":2,"name":"Front-end","item":"https:\/\/uniquedevs.com\/blog\/category\/front-end\/"},{"@type":"ListItem","position":3,"name":"TanStack Table &#8211; flexible and powerful tables in React"}]},{"@type":"Website","@id":"https:\/\/uniquedevs.com\/#website","url":"https:\/\/uniquedevs.com\/","name":"Software House - rozwi\u0105zania IT dla Twojego biznesu | UniqueDevs","description":"","publisher":{"@id":"https:\/\/uniquedevs.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/uniquedevs.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},[],{"@type":"Person","@id":"https:\/\/uniquedevs.com\/#\/schema\/person\/a2c9b776ac544a910615b03c8b9c4c18","name":"Hubert Olech","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/uniquedevs.com\/#\/schema\/person\/image\/","url":"https:\/\/uniquedevs.com\/wp-content\/litespeed\/avatar\/4aa41b6b162ba5c7c2dc5577af43de87.jpg?ver=1776685844","contentUrl":"https:\/\/uniquedevs.com\/wp-content\/litespeed\/avatar\/4aa41b6b162ba5c7c2dc5577af43de87.jpg?ver=1776685844","caption":"Hubert Olech"},"description":"Huber Olech - Founder @UniqueDevs. \u0141\u0105cz\u0119 \u015bwiat technologii z biznesem, pomagaj\u0105c firmom rozwija\u0107 si\u0119 dzi\u0119ki innowacyjnym rozwi\u0105zaniom cyfrowym. Pasja do software development zainspirowa\u0142a mnie do zbudowania zespo\u0142u ekspert\u00f3w, z kt\u00f3rymi wsp\u00f3lnie dostarczamy najwy\u017cszej jako\u015bci produkty dla swoich Klient\u00f3w. W oparciu o swoje wieloletnie do\u015bwiadczenie w bran\u017cy IT, rozumiem trendy w nowych technologiach i potrafi\u0119 przeku\u0107 je w wymierne korzy\u015bci dla firm. Moj\u0105 misj\u0105 jest tworzenie rozwi\u0105za\u0144, kt\u00f3re nie tylko usprawniaj\u0105 procesy, ale tak\u017ce otwieraj\u0105 przed Klientami nowe mo\u017cliwo\u015bci rynkowe i zwi\u0119kszaj\u0105 ich konkurencyjno\u015b\u0107.","sameAs":["https:\/\/www.linkedin.com\/in\/hubert-olech-b0a524167\/"],"url":"https:\/\/uniquedevs.com\/en\/blog\/author\/h-olech\/"}]}},"_links":{"self":[{"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/posts\/3887","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/comments?post=3887"}],"version-history":[{"count":2,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/posts\/3887\/revisions"}],"predecessor-version":[{"id":3891,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/posts\/3887\/revisions\/3891"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/media\/4832"}],"wp:attachment":[{"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/media?parent=3887"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/categories?post=3887"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/uniquedevs.com\/en\/wp-json\/wp\/v2\/tags?post=3887"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}