cannot reinitialise datatable

In this tutorial, we will discuss how to fix the error, Datatables warning(table id = ‘example’): cannot reinitialise data table.

Datatables warning(table id = ‘example’): cannot reinitialise data table

The error came while I was trying to retrieve more than 5000 items using Rest API from a SharePoint Online list and was trying to bind the data to DataTables.

Here, I was using the code below:

$('#Employee').DataTable({
	"aaData": response,
	"aoColumns": [
	{
	"mData": "Title"
	}
	]
	});

But it gave the error when I tried to execute the code. It gave error as:

DataTables warning: table id=Employee – Cannot reinitialise DataTable. For more information about this error, please see http://datatables.net/tn/3

cannot reinitialise data table

To fix the error, you need to add the below attribute.

"bDestroy": true

It will look like below:

$('#Employee').DataTable({
	"aaData": response,
	"bDestroy": true,
	"aoColumns": [
	{
	"mData": "Title"
	}
	]
	});

After this, the error did not come; this fixes the issue Datatables warning(table id = ‘example’): cannot reinitialise data table.

I hope this solution will help you to fix the error, datatables warning: table id=example – cannot reinitialise datatable. for more information about this error.

You may also like:

Leave a Comment

⏰ LIMITED-TIME OFFER

Join the SharePoint & Power Platform Developer Live Training

📅 Live training starts October 5, 2026
SharePoint Development
Power Apps & Power Automate
Copilot Studio
🎁
FREE 1-Year Access to SPGuides.Academy

Enroll now and get access to all 9 academy courses at no extra cost.

Secure your seat before the batch fills up.
Get the live training plus the complete SPGuides.Academy learning library.

Enroll Now & Get Your FREE 1-Year Academy Access → View live training details and schedule
Power Apps functions free pdf

30 Power Apps Functions

This free guide walks you through the 30 most-used Power Apps functions with real business examples, exact syntax, and results you can see.

Live Webinar

SharePoint Integration Power Apps Form With Repeating Table [Invoice Management System]

Learn how to build an invoice management system using SharePoint integration and a repeating table.

📅 2nd September 2026 – 10:00 AM EST | 7:30 PM IST

Download User registration canvas app

DOWNLOAD USER REGISTRATION POWER APPS CANVAS APP

Download a fully functional Power Apps Canvas App (with Power Automate): User Registration App