Connecting data

How to refresh, edit or remove a data source

How to refresh, edit or remove a data source

In TeleportHQ, every data source is managed from its card in the Data Sources panel. Click the card to rename it or change its connection details, or click the refresh button to pick up tables you added in your database. To delete it, click the card's trash button; every element bound to it is unbound.

Before you start

  • Removing a data source or a table can turn off features that use it, such as Authentication, E-Commerce, the Admin Panel, the AI Assistant Chat, the Blog or the Help Center. Read the confirmation window carefully.
  • Removing a table deletes the table and its rows from the database itself. Back up the data first.
  • A headless CMS is managed differently. See Connect a headless CMS.

Open a data source in TeleportHQ

  1. In the left sidebar, click Data Sources (the database icon).
  2. Click the data source's card, for example Gym members. Its settings open beside the panel, titled Update and the type, for example Update PostgreSQL.
A data source card in the TeleportHQ Data Sources panel, with its name, its type and the trash button Delete data source highlighted

Refresh a data source's tables in TeleportHQ

Use refresh when you added tables or columns directly in your own database and TeleportHQ doesn't show them yet. It works for the TeleportHQ database, Supabase, Airtable and every database type.

  1. Open the data source (see above).
  2. In the Database Tables (or Confirmed Data Sources) header, click the refresh button. Its tooltip starts with "Refresh all the tables/collections available in the data source."
The Database Tables header of a TeleportHQ data source with the refresh button highlighted

A message confirms "Data source schema refreshed successfully". New tables now appear in the list.

Change a data source's connection details

To change a password, host or other setting of a TeleportHQ data source:

  1. Open the data source.
  2. Expand the Setup … Connection section, for example Setup PostgreSQL Connection.
  3. Change the field, for example type the new Password.
  4. Click Fetch Database Schema again. For Redis and Airtable, the buttons are Fetch Redis Schema and Fetch Airtable Schema.

For a REST API, Google Sheet or CSV file, change the field, load the data again (Fetch data from API, Get data from Google Sheet or Extract data from CSV), then click Save Data Source. For a JavaScript list, edit the code and click Save Data Source.

If the field is linked to a Secret, change the Secret instead in Project settings → Data & code → Secrets. See Keep passwords and API keys safe.

Rename a data source

  1. Open the data source.
  2. Click into Data Source Name and type the new name, for example Members.
  3. Click anywhere outside the field. The name saves.

If another data source already has that name, TeleportHQ adds a number to the end.

Remove one table from a data source

You can remove a table from the TeleportHQ database, Supabase, PostgreSQL, MySQL, MariaDB, Amazon Redshift, CockroachDB and TiDB.

  1. Open the data source.
  2. In Database Tables, find the table and click the ⋯ button at the right of its row, next to View Data.
  3. Click Delete.
The menu of a table row in a TeleportHQ data source, with Delete highlighted below Add Data as Table in Page
  1. A window titled Delete Table asks "Are you sure you want to delete this table?". Click Delete Table.

A message confirms Table "<name>" deleted successfully. If the database refuses, the message starts with "Failed to delete table:" and gives the reason.

If a feature or workflow uses the table, a Table In Use window lists what will be turned off or reset. Type delete table in the box to confirm.

Delete a data source

  1. In the Data Sources panel, find the data source's card.
  2. Click its trash button (tooltip Delete data source).
  3. The Delete Data Source window says: "You are about to permanently delete this data source from your project. All nodes currently bound to this data source will be unbounded."
  4. Click Delete Data Source.

For a TeleportHQ database, the window is titled Delete the "…" database instead, with your database's name, and says: "This is a TeleportHQ database: every table and every row in it is deleted together with the data source, and the data cannot be recovered. All elements bound to it will be unbound." Its button reads Delete database and data.

If features or workflows use the data source, the Data Source In Use window appears instead. It lists them under Important:, for example "Blog will be disabled", and for a TeleportHQ database it adds that every table and every row in it "will be deleted and cannot be recovered". Type Delete data source in the box and click Delete Data Source. Those features are turned off, and workflow steps that used its tables are reset.

Check that it worked

  • After a refresh, new tables show in the data source's table list.
  • After editing, the card still appears and its tables load when you click View Data.
  • After deleting, the card disappears from the Data Sources panel, and elements that used it are no longer bound to data.

Troubleshooting

"Failed to fetch database schema. Make sure that the configuration is correct." The connection details are no longer valid, for example the password changed. Update them and click Fetch Database Schema.

"Failed to update data source schema" TeleportHQ read the tables but couldn't save the update. Try again. If it keeps failing, contact support.

The CMS connection card has no trash button Remove a headless CMS with ⋮ → Disconnect CMS. See Connect a headless CMS.

A table has no Delete in its menu MongoDB, Redis, Firestore, ClickHouse, Airtable and Turso tables can't be removed from TeleportHQ. Remove them in the database's own tools, then refresh the data source.

Good to know

  • Deleting your own database's connection keeps the database. For PostgreSQL, MySQL, MongoDB, Supabase, Airtable and the other external services, deleting the data source only removes the connection from the project.
  • Deleting the TeleportHQ database deletes its data. When you delete a TeleportHQ database data source, TeleportHQ also deletes the hosted database with all its tables and records, as its delete window warns. Export the records you need first. See Set up the built-in TeleportHQ database.
  • Deleting can't be undone. To get the project's settings back, restore a project backup. See Back up and restore your project.
Share

Related Articles

What are data sources, and which ones can I connect?

A data source is a connection that brings content from a database, spreadsheet, API or headless CMS into your TeleportHQ project, so your pages show real data instead of typed text; you manage them in the editor's Data Sources panel, and connecting one keeps a website a website.

How to connect a database (PostgreSQL, MySQL, MongoDB, Firestore and more)

In TeleportHQ, you connect your own database from Data Sources → Add Data Source, by entering its connection details and clicking Fetch Database Schema, which adds all its tables to your project.

How to keep passwords and API keys safe (Secrets)

TeleportHQ stores passwords, tokens and API keys as project Secrets, which the project owner manages in Project settings → Data & code → Secrets and links to credential fields with the plug button, instead of typing the value into each data source.

How to view, add and edit records

In TeleportHQ, you manage a database table's rows in its table window, opened with View Data in the Data Sources panel: click Create Record to add a row, double-click a cell to change it, open a row's menu for View Details or Delete Record, and use the SQL view to look up rows with a query.

Why does my data look different in the editor and on my live site?

In TeleportHQ, the editor and your published site load data separately: design and filter changes need a publish, cached lists and cached REST API responses can show older content for a while, CMS pages refresh on their own schedule, and data changed outside TeleportHQ needs a Refresh in the editor.

How to back up and restore your project

In the TeleportHQ editor, click Backups in the bottom toolbar, then Backup current project state to save a snapshot, or Restore next to a backup (such as Before Web App features Enabled) to bring the project back to that point; backups need a Pro or Premium plan, trial users ask support to restore, and you must republish afterwards.