Sync a CMS collection from Airtable
Fill a collection with the records of an Airtable table, their attachments as assets and their linked records as references, kept up to date on a schedule or when you sync, with nothing ever written to Airtable.
On this page 2 sections
Before you start
- A paid site planSee plans
A CMS collection can take its items from an Airtable table: products, properties for sale, a menu. Each record becomes an item. Attachments become your site's assets, and linked records become references to the items of another synced collection. The records and their attachments are copied from your Airtable base into our storage in the EU when the collection syncs, so your site never loads anything from Airtable when someone visits it, and nothing is ever written to Airtable.
Before you start
The table is read with a personal access token of your own:
- In Airtable, open the Builder hub, then Personal access tokens, and create a token with the
data.records:readandschema.bases:readscopes. - Give the token access to the base the table is in. Copy the token.
Connect the table
- Open the collection. In its toolbar, choose Sync from…, then Airtable.
- In Personal access token, paste the token. It is stored encrypted.
- In Table link, paste the table's link from Airtable. It names the base and the table (
airtable.com/app…/tbl…); a link to one of the table's views works too. - Choose Read the fields. The table is read once, and each field gets a line with a few of its values and a suggested type.
- Choose how often to Sync: Only when I sync, Every hour or Every day (the default). Publish new items at once is on: new items are published as they arrive. Turn it off to review new items before you publish them.
- Choose what happens When a record is deleted in Airtable: Archive its item (the default), Delete its item or Keep its item.
- Choose Connect and sync. The new fields are made, and the first sync starts at once.
If the collection already holds items from an earlier source, and the new source may not have them, the dialog first says how many: “Up to 12 items synced from an earlier source will be archived if the new source doesn’t have them.” It says “deleted” for Delete its item and asks nothing for Keep its item. Choose Cancel, or Connect anyway. Nothing is removed before you choose.
Each record is known by its own ID in Airtable, so a record whose fields change updates its item, even when its name changes.