Pagerail – Sync from Notion
Sync Notion to WordPress: publish a Notion database as posts, pages or custom post types, with Gutenberg blocks, local images and scheduled sync.
Install in
Write in Notion, publish in WordPress. Pagerail turns the rows of a Notion database into WordPress posts or pages and keeps them up to date. Content becomes native Gutenberg blocks, images are copied into your Media Library, and nothing on your site depends on Notion staying online.
Pagerail syncs any number of Notion databases and single pages, with no limit on sources or rows.
What it does
- Database posts, pages or any post type. One sync source maps one Notion database to the post type you choose: posts, pages or any public custom post type that uses the editor. Single Notion pages can be synced too.
- Field mapping with sensible defaults. Title, slug, status, publish date, excerpt, categories, tags and featured image (a files/URL property or the page cover). Pagerail suggests the mapping from your property names and types.
- Status mapping. Map Notion status/select/checkbox values to Published, Draft, Pending review, Private or “don’t sync”. Optional row filter (“only rows where Publish is checked”).
- Real block editor content. Paragraphs with bold/italic/strikethrough/code/underline and links, headings, nested bulleted/numbered lists, to-do lists, quotes, callouts, code with language, dividers, tables, toggles (as Details blocks), columns, images with captions and alt text, video/embeds (oEmbed when WordPress supports the provider), bookmarks, files and PDFs, equations, synced blocks. Nested toggles and callouts work at any depth. Posts open in the block editor without “invalid block” warnings.
- Images that don’t break. Notion file links expire after an hour, so Pagerail downloads images into the Media Library, de-duplicates them and reuses them on later syncs.
- Links between pages. A link or mention of another synced Notion page becomes the WordPress permalink. Otherwise it links to the Notion page or becomes plain text (your choice).
- Readable on every theme. Notion text colours are ignored by default (optional setting to keep them).
- Incremental and safe. Only changed rows are rewritten. Rows deleted or archived in Notion can move the post to the Trash, back to Draft, or be ignored. Large databases sync in small batches that resume where they stopped, so there are no server timeouts.
- Adopt existing posts. Optionally match Notion rows to existing WordPress posts by slug or by a “WP ID” property, so old content can be managed from Notion without duplicates.
- Scheduled sync (WP-Cron) every 15 minutes, hourly, twice daily or daily, a Sync now button with live progress, and a warning when WP-Cron has not run recently.
- Clear onboarding. After you paste your Notion API token, Pagerail shows exactly which databases your connection can see. If it sees none, it tells you how to share a database with the connection.
- Sync log and diagnostics. The last 200 log entries on the settings page, an admin notice on errors, and a Copy diagnostics button (versions, settings and recent log lines, never your token) for support requests.
- Per-post actions. “Re-sync from Notion” and “Edit in Notion” links in the Posts and Pages lists.
- WP-CLI.
wp pagerail sync [--source=<id>] [--dry-run] [--force],wp pagerail sources,wp pagerail log,wp pagerail connect,wp pagerail add-source. A real server cron job runningwp pagerail syncworks on cached or password-protected sites where WP-Cron does not fire.
An optional, separate add-on is available at https://nosubz.com/extensions/pagerail.
Privacy
Pagerail does not track you and sends no data to the plugin author. It only talks to the Notion API with the token you provide, and downloads the images and files that your Notion pages contain. See “External services” below.
External services
This plugin connects to the Notion API (https://api.notion.com), a service run by Notion Labs, Inc., to read the databases and pages you have shared with your Notion connection.
- What is sent: your Notion API token (in the Authorization header) and the IDs of the databases, data sources, pages and blocks to read. No data about your WordPress site or its visitors is sent.
- When: when you click “Test connection”, list databases, add a sync source or sync (manually, on the schedule you choose, or with WP-CLI).
- Files: images and files in your Notion content are downloaded from the URLs Notion provides (usually Notion’s Amazon S3 storage,
prod-files-secure.s3.us-west-2.amazonaws.com), or from the external URL you embedded. OnlyhttpsURLs on public addresses are downloaded. - Notion terms of use: https://notion.notion.site/Terms-and-Privacy-28ffdd083dc3473e9c2da6ec011b58ac
- Notion privacy policy: https://www.notion.com/trust/privacy-policy
Written by Joobi from the project's own listing. See the source page
0.1.1
- No limit on the number of database sources.
- Any public post type that uses the editor can be a sync target (not only posts and pages).
- Sync frequency setting: every 15 minutes, hourly, twice daily or daily.
- Source editor input is read field by field and sanitized before it is used.
- The sync lock is now atomic (two simultaneous syncs can no longer both start).
- Updated links to Notion’s terms and privacy policy.
0.1.0
- First release: Notion database and single-page sync to posts or pages, field and status mapping, row filter, Gutenberg block conversion, Media Library image import with de-duplication, links between synced pages, incremental and resumable batches, hourly WP-Cron sync, removal handling (trash/draft/ignore), adopt existing posts, sync log, diagnostics, row actions, WP-CLI commands, uninstall cleanup.
Follow this listing's changes (Atom feed)