
Prefect Cloud
Let AI connect your sources for you
Skip the manual setup — run this in your project and the wizard auto-detects your databases and APIs and connects them to PostHog.

Connect Prefect Cloud to PostHog to sync your data into the PostHog data warehouse for analysis and modeling.
Enter your Prefect Cloud account ID, workspace ID, and an API key to pull your flow and task run history into the PostHog Data warehouse.
Both IDs are in your workspace URL: https://app.prefect.cloud/account/<account ID>/workspace/<workspace ID>.
Create an API key under API keys in your profile settings, or use a service account key on paid tiers. The key inherits the owner's permissions, so read access to the workspace is all it needs.
Configuration
| Option | Type | Required |
|---|---|---|
Account ID | text | Yes |
Workspace ID | text | Yes |
API key | password | Yes |
Linking Prefect Cloud to PostHog
- Go to the Data pipeline page in PostHog
- Click New source and select Prefect Cloud
- Fill in the required configuration fields
- Click Next, select the tables you want to sync, and then press Import
Supported tables
| Table | Description | Sync method | Incremental field | Primary key |
|---|---|---|---|---|
flows | A flow is a Prefect workflow definition — the top-level container that flow runs are instances of. | Full refresh | — | — |
flow_runs | Incremental syncs re-read a 24-hour trailing window so recently started runs pick up state changes; runs that change state later than that are only refreshed by a full refresh | Incremental, Full refresh | start_time, expected_start_time | — |
task_runs | Incremental syncs re-read a 24-hour trailing window so recently started runs pick up state changes; runs that change state later than that are only refreshed by a full refresh | Incremental, Full refresh | expected_start_time | — |
deployments | A deployment is a server-side representation of a flow that can be scheduled and triggered remotely, with its schedule, work pool, and parameters. | Full refresh | — | — |
work_pools | A work pool organizes and distributes flow runs to workers of a given infrastructure type. | Full refresh | — | — |
work_queues | A work queue within a work pool that prioritizes and delivers flow runs to workers. | Full refresh | — | — |