If you've migrated your site to a new domain or hosting environment and your wpDataTables tables show up empty or aren't working correctly, you're likely dealing with one of two common issues:
The file path to your data source files (Excel, CSV, etc.) has changed
The database table prefix is different on the new site
This guide will help you resolve both!
When you move your site to a new domain or hosting setup, the internal file system path to your uploaded files often changes. This can break tables that are linked to Excel, CSV, or other file types, because the plugin can't locate the file in the new path.
Create a new test table on the new site, linked to any Excel or CSV file.
Go to your database using phpMyAdmin (or another DB tool).
Open the table:
your_prefix_wpdatatables
Note:
your_prefix_
will vary — it might bewp_
,xyz_
, or something else depending on your site's DB prefix.
In the content
column, you’ll see the full server path to the newly uploaded file.
Example:
New table path:
/var/www/html/your_NEW_site/wp-content/uploads/2021/02/file-one.xls
Old table path (from migration):
/var/www/html/your_OLD_site/wp-content/uploads/2021/02/file-two.xls
To update the old paths in bulk, run this SQL query:
UPDATE your_prefix_wpdatatables SET content = REPLACE(content, '/var/www/html/your_OLD_site/', '/var/www/html/your_NEW_site/');
This will update all references to the correct file path.
If you're using Manual or SQL-based tables, another common issue after migration is that your WordPress database table prefix has changed (e.g., from wp_
to xyz_
).
wpDataTables stores these prefixes, so the plugin might still be trying to load tables like wp_wpdatatable_1
, while your actual tables are now named xyz_wpdatatable_1
.
Open your database via phpMyAdmin or your host’s DB tool.
Run the following query on the your_prefix_wpdatatables
table:
UPDATE your_prefix_wpdatatables SET mysql_table_name = REPLACE(mysql_table_name, 'wp_', 'xyz_');
Replace:
'wp_'
with your old site’s table prefix
'xyz_'
with your current site’s prefix
This updates the table references so wpDataTables can load your data correctly.
If you're not sure what your current prefix is:
Open your wp-config.php
file (in your site root folder).
Look for the line:
$table_prefix = 'xyz_';
That’s your current prefix (e.g., xyz_
).
If you've followed the above steps and your tables still aren't loading correctly:
Reach out to our Support Team via the chat box in the bottom right corner of the site. We're happy to investigate further and help you get everything working smoothly.