Export and Import Custom Database Tables with Google Sheets

In this tutorial, we’ll show you how to export and import WordPress custom database tables with Google Sheets.

In a previous tutorial, we showed you how to bulk edit custom database tables in a spreadsheet on the WordPress admin dashboard.

In this post, we’ll guide you step by step to connect your WordPress site to your Google Sheets account to export and import custom database tables with a few clicks.

This is great because you can save your database tables’ data on Google Sheets, edit custom database tables in Google Sheets, and then import custom database tables from Google Sheets.

We will use the WP Sheet Editor – Custom Database Tables plugin, which allows you to view and manage custom database tables using an intuitive spreadsheet on the WordPress admin dashboard.

We will also use the Google Sheets Sync service, which allows you to connect WordPress with Google Sheets to export and import content easily.

You can sign up to the service here:

Sign up to the Google Sheets Sync Service - or - Check the features

You need to follow the steps in the sections below to export and import custom tables with Google Sheets on WordPress.

1- Generate your custom database table spreadsheet in wp-admin

The first thing you need to do is to generate a spreadsheet for the custom database table you want to edit in wp-admin.

You can do that with these simple steps:

  1. Go to WP Sheet Editor > Setup Spreadsheet.
  2. Select the custom table you want to edit in wp-admin.
  3. Select the columns you want to display in the spreadsheet.

Done! After these steps, you’ll see a spreadsheet for the custom table you selected. In this example, we’re using the WC Order Coupon Lookup table.

Export and Import Custom Database Tables with Google Sheets

2- Connect WordPress with Google Sheets

When you subscribe to the Google Sheets Sync service, you will get a helper plugin that will allow you to connect your website with your Google account, the Google API, and the WP Sheet Editor API.

You can follow this installation and configuration guide to learn how to connect WordPress to Google.

3- Export custom database tables to Google Sheets

To export custom database tables to Google Sheets, you need to open the Export tool.

Export custom database tables to Google Sheets

Then, you need to select the following values:

  • What columns do you want to export: You need to select the columns you want to export here.
  • Which rows do you want to export: You can export all rows, all the rows from a specific search, or all the rows you manually select in the spreadsheet.
  • What app will you use to edit this field: Google Sheets
  • Name of this export: You can add a name for this export, and the Google Sheet will inherit that name.
  • Click on Start new export.

Export custom database tables to Google Sheets

After the export process is complete, you’ll see the View Google Sheet link. You can click on it to open the Google Sheet that was generated with this export.

Export custom database tables to Google Sheets

4- Manage custom database tables in Google Sheets

Here you can see the Google Sheet we generated.

It’s a great way to view and manage WordPress custom database tables in Google Sheets! You can keep this file, edit the data, etc.

Manage WordPress custom database tables in Google Sheets

5- Import custom database tables from Google Sheets

WP Sheet Editor allows you to import custom database tables from Google Sheets with a few clicks.

But before importing, there are some things to keep in mind:

  • To protect your privacy, our Google Sheets Sync service doesn’t read files that have not been created with the service itself.
  • In other words, the service doesn’t recognize files that were not first exported from WordPress to Google Sheets using the service.
  • This means that we don’t have any access to other files on your Google account; not even to other Google Sheets files.
  • Therefore, to import a Google Sheets file, you’ll need to first export the info.
  • Once you’ve exported it, you can edit existing data or create new data in Google Sheets.

First, open the Import tool.

Import custom database tables from Google Sheets

Second, select the Google Sheets file you want to import:

  • Source: Google Sheets
  • Google Sheet file: Select the file you’ll import here. If you don’t find it, click on “refresh”.
  • Click on Next.

Import custom database tables from Google Sheets

Third, select the columns you will import from Google Sheets into WordPress.

You can Import all the columns or Select individual columns to import.

Import custom database tables from Google Sheets

Fourth, select how you want to import the data.

Since we’re updating a custom database table, we will Update existing items, ignore new items.

This means we need to match the rows in Google Sheets with the fields on WordPress. We’ll use the ID field to match the data.

Click on Next.

Import custom database tables from Google Sheets

Finally, you need to click on The preview is fine, start import.

export-import-custom-database-tables-google-sheets

As you can see, exporting and importing WordPress custom database tables with Google Sheets is easy with the WP Sheet Editor plugin and the Google Sheets Sync service! You can save custom databases to Google Sheets, manage your custom tables’ data in Google Sheets, and import custom tables from Google Sheets into WordPress.

Do you need help?

You can receive instant help in the live chat during business hours, or you can contact us and we will help you via email.