Connecting Apache Superset to the CKAN DataStore for open data dashboards
The integration is a direct PostgreSQL read connection from Apache Superset to the CKAN DataStore database, made with the read-only datastore_default user. Superset reads the DataStore tables directly and does not call the CKAN Data API, so its queries skip the API entirely. This page covers the prerequisites, the read path from a published resource to a chart, the Superset setup, the mapping from DataStore tables to dataset and resource names, the boundary between private resources and public dashboards, testing, and the failure points that appear most often. Confirm any community connector against your CKAN version before adopting one, because CKAN minor releases can include backwards-incompatible changes and connectors often lag behind them.
Start by confirming that each tabular resource has been loaded into the DataStore. XLoader is the officially supported loader and DataPusher is legacy, so a resource that was never loaded has no table for Superset to query. In CKAN, ckan.datastore.write_url and ckan.datastore.read_url define the two database logins. Superset should receive only the read connection and its password from a secrets store. Each resource alias is exposed as a database view listed in _table_metadata, so build charts on these alias views rather than on raw resource tables, and document which alias belongs to which dataset. Confirm in your CKAN version how aliases behave when a resource is replaced. The CKAN DataStore documentation describes the tables and views in more detail. Keep Superset's own metadata database separate from the DataStore database.
The most important decision is the private resource boundary. The read-only user is a PostgreSQL login, so PostgreSQL does not apply CKAN's dataset visibility or organization roles. A Superset dataset built on a DataStore view can therefore return rows from a resource that is private in CKAN. Decide before building: either keep private data in a database or schema the read user cannot reach, or expose only views that exclude it, and confirm which option your CKAN version supports. To test, sign in to Superset with an account that should not see a private resource, query its view, and record what returns. Common failure points include a missing read URL or database grant, a view that does not exist because the resource was never loaded, data that lags the latest upload, and a Superset start-up error because no SECRET_KEY is set.
What connecting Apache Superset to the CKAN DataStore requires first
Five decisions and checks come before any dashboard is built. Each one sets a version, a database or an access boundary that the next step depends on, so confirm them in your environment before installing Superset. Confirm them in writing with your CKAN, database and security teams before installation starts.
CKAN version and loaded DataStore
Run CKAN 2.12.0 or a 2.11 patch release such as 2.11.6, the two current minor lines, and confirm which loader filled each table. XLoader is the officially supported loader, while DataPusher is now legacy, so any table filled only through DataPusher needs a review before you build on it. Superset can only query what sits in the DataStore, so a resource that exists only as a file in the FileStore will not appear as a table.
DataStore docsDataStore PostgreSQL version
The DataStore runs in its own PostgreSQL database, and PostgreSQL 14 reached end of support on November 12, 2026. Check the major version on the DataStore server and plan a move to a supported major, since CKAN itself needs PostgreSQL 12 or newer. Test the upgrade on a copy of the DataStore database first, then confirm that the read-only user and the Data API still work after the switch.
- PostgreSQL 14 end of support
- Nov 12, 2026
Superset release to deploy
Pin one stable Superset release and record the exact version in your deployment files. PyPI lists 6.1.0 as published on May 13, 2026, while the GitHub releases page lists 7.0.0rc2 as a pre-release from October 16, 2026. Pre-releases are meant for testing, so check the GitHub releases page for the current stable release before you begin. If a stable 7.0.0 is listed, review its upgrade notes separately from this build.
Superset releasesSuperset metadata database
Superset keeps its own dashboards, users and settings in a metadata database, separate from the DataStore. Use PostgreSQL 10 to 17 or MySQL 5.7 or 8.x, the versions listed in the configuration documentation. PostgreSQL 18 is not on that list, so confirm support with the Superset project before you choose it. SQLite is the default for quick installs and is not for production, and you should back up this database before every upgrade.
Superset configuration docsNetwork path, TLS and read credentials
Superset should connect with only the read-only database user, the one configured through ckan.datastore.read_url, and the write user that owns the DataStore should stay out of Superset's settings. Decide who holds that password, where Superset stores it and how it is rotated. Confirm with your network and database teams that the path from Superset to the DataStore server is limited to approved hosts and ports, and that TLS is enabled on that connection.
- DataStore database users
- 2
Why the DataStore database is the integration point
The DataStore database is the point where Superset should connect, because CKAN keeps structured resource data in its own PostgreSQL database, separate from the portal's metadata. CKAN reads two settings for it: ckan.datastore.write_url points at a write user that owns the database, and ckan.datastore.read_url points at the read-only datastore_default user that handles queries. Superset needs only the read connection. Each DataStore resource is a table, and each resource alias is a database view listed in _table_metadata, so dashboards can reference the alias and leave the internal table name alone. Confirm that the read role can see the views you plan to chart and no others, because that role's grants decide what Superset can query. The CKAN DataStore documentation sets out these settings.
The FileStore and the DataStore hold different things. The FileStore keeps whole uploaded files, so Superset has no reason to download them. The DataStore holds the rows and supports row-level access and querying. The Data API is a second path into the same rows. It runs through CKAN, applies CKAN's own access checks on each request, and offers filtering, full-text search, pagination and SQL queries. A Superset connection to PostgreSQL skips that layer, so the checks CKAN makes on an API request do not apply to Superset queries. Decide which path governs each dataset before the first chart is built, and record that decision in the dashboard design notes.
Direct SQL access gives the team full SQL, joins across resources and Superset's dataset and chart tools running on PostgreSQL. It also keeps analytical load off the CKAN web application. In return, the team gives up CKAN's per-request checks and the query interface and paging that the Data API provides. The read role's PostgreSQL grants become the only access control on those tables, so a private resource's table is reachable by anyone holding the read credential unless the grants exclude it. Ask the portal owner to confirm which tables the read role can select, to review that list after each XLoader load, and to check that the PostgreSQL major version is still supported, since PostgreSQL version 14 reached end of support on November 12, 2026.
How Superset reads DataStore views inside a trust boundary
The diagram starts in the DataStore host, where CKAN hands uploads to XLoader and XLoader loads rows through the write user into private resource tables. Approved views sit over those tables, and the read-only datastore_default role selects only from those views. Superset connects through that read-only role across the boundary into its own network zone, where its separate metadata database stores its dashboard definitions. The control point is the view layer. Check that the read role holds no grants on private tables and that the Superset connection uses only the read-only credentials.
Superset reads only approved views through a read-only role across the trust boundary.
Connecting Apache Superset to the CKAN DataStore read user, step by step
This sequence connects Apache Superset to the CKAN DataStore through the read-only database role, so dashboards can only query views that a data steward has approved for public resources. Each step closes with a check you can run in your own environment, such as a rejected write or a private table that does not appear in Superset. The result is a documented connection that your security and data teams can review before any chart reaches a public audience.
Confirm the read and write URLs
The CKAN administrator checks the
ckan.datastore.write_urlandckan.datastore.read_urlvalues in the CKAN configuration and notes the database host, port and role each one uses. The write URL belongs to the owning user and stays with the CKAN deployment. Only the read URL, which points at the read-onlydatastore_defaultrole, goes forward to Superset. Confirm that the read URL targets the DataStore database and not the CKAN main database, and that its role owns no tables. Done when the host and read role name are written down and a connection made with the read URL alone succeeds.Inventory DataStore tables and aliases
The CKAN administrator lists the resource aliases in the
_table_metadatatable and maps each alias and its underlying table to the CKAN resource and dataset it belongs to. For every dataset, the team checks its visibility in CKAN and marks it as public or private, since the DataStore read role does not apply CKAN's organization permissions. Data stewards approve the public aliases that dashboards may use, and the list is stored with the connection documentation. Done when every alias has an owner, a visibility status and an approval decision, and no private resource appears on the approved list.Grant select rights on approved views only
A database administrator creates or confirms a view for each approved alias and grants
SELECTon those views to the read role, after revoking any broader rights that role received from the default setup. The role receives no rights on the raw resource tables or on objects owned by the write role. The administrator then tests the role directly in PostgreSQL. Done when aSELECTon an approved view succeeds, aSELECTon a private table fails, andINSERT,UPDATE,DELETEandCREATEattempts are rejected for the read role.Open a TLS path to the database host
The network team opens one path from the Superset application and worker hosts to the PostgreSQL port on the DataStore database host, and blocks other destinations from those hosts. The connection must require TLS, and the team confirms the server presents a certificate that the Superset hosts trust. Ask the database team to confirm the authentication method for the read role, since current PostgreSQL releases favor SCRAM over MD5 password authentication. Done when a TLS connection from a Superset host succeeds, while a plaintext attempt or a connection from any other host is refused.
Create and test the Superset database connection
In Superset, an administrator creates a database connection that uses the read role credentials, the DataStore database host and the TLS settings from the previous step. Keep the password in your secret store and limit who can edit the connection. Run the connection test in the Superset interface before saving. Done when the test connection succeeds and the saved connection shows the read role name, which confirms that no write credentials were entered.
Register only approved views as datasets
A data analyst adds datasets in Superset only from the approved views, using the schema and view names the database administrator created. Each dataset gets a name that matches the public CKAN dataset it describes, and the team records the source alias beside it. Check whether a private table appears in the dataset list or the schema browser. If a private table name is visible, confirm with the database team whether the role can list names it cannot read. Done when no private table is registered as a dataset and every dataset traces to an approved view.
Build charts and dashboards with role access
Analysts build charts on the registered datasets and assemble dashboards that use only those datasets. The team sets dashboard and dataset access through Superset roles, so public dashboards are visible to a viewer role and editing rights stay with a small group of builders. Map identity groups to Superset roles through your identity provider or LDAP configuration, so access follows group membership. Done when a test account in the viewer role opens the public dashboard and cannot open the editor or the datasets it was not granted.
Run the verification pass
The security or data team repeats the checks from the earlier steps against the live environment: a write attempt by the read role, a
SELECTon a private table, the Superset dataset list, and a viewer account's dashboard access. They file the results with the approved alias list and the date of the check. Repeat the pass after any change to CKAN dataset visibility, any new alias, or any Superset upgrade, and review UPDATING.md for breaking changes before upgrading. Done when every check returns the expected result and the record is filed with the connection documentation.
How DataStore tables map to Apache Superset datasets and access
This table compares each CKAN and DataStore element with its Apache Superset counterpart and shows whether the mapping is automatic, needs a manual allowlist, or requires a design decision. Read it as a checklist for your access model. The main takeaway is that Superset does not inherit CKAN visibility or organization roles, so access control has to be designed at the database connection and in Superset roles.
| Element | How it maps | Mapping type |
|---|---|---|
| CKAN resource to DataStore table | Loaded resources become tables in the DataStore database. Confirm the table naming convention in your own DataStore before building datasets. | Automatic once loaded |
| Resource alias to view listed in _table_metadata | Aliases are views listed in _table_metadata. Register only the views you intend to expose. | Manual allowlist |
| CKAN dataset visibility to Superset dataset access | Private CKAN datasets do not restrict the read-only database user. Anyone who can query that connection can read the underlying tables. | Design decision |
| CKAN organization and role to Superset role | CKAN organization roles do not carry into Superset roles. Decide which groups map to which Superset roles before you set up access. | Design decision |
| Read role to Superset database connection | Point the Superset connection at the read-only datastore_default user and keep the write user out of Superset. | Design decision |
Keeping private CKAN resources out of public Apache Superset dashboards
Superset reads from the DataStore database, so CKAN's dataset visibility does not carry over to it automatically. The controls below decide which tables and rows a dashboard can reach, who can publish it, and how people and services authenticate. Check each one in your own environment before any dashboard is shared beyond your team.
Read-only role scope
The read-only database user behind ckan.datastore.read_url queries PostgreSQL directly, and CKAN dataset visibility does not filter that access. A Superset user who can read a private resource's table can read all of its rows. Build the exclusion into views and grants: give Superset a role with select rights on approved resource views only. Verify it by running a query as that role against a private resource and confirming it fails.
Dashboard publishing and role access
Superset is built on Flask-AppBuilder, so its roles decide who can open, edit and publish a dashboard and which database connections a user can see. Keep the DataStore connection out of reach of analyst roles, and publish dashboards only to approved roles matched to the audience the data was cleared for. Confirm the exact permission names for your Superset version. Verify by signing in as an analyst account and confirming it cannot open the connection settings or a dashboard meant for another group.
Superset sign-in separate from CKAN
Superset signs users in through its own configuration, separate from CKAN accounts, so disabling a CKAN account does not revoke Superset access. Superset supports OAuth2 providers, LDAP and custom OAuth2 servers, and AUTH_ROLES_MAPPING turns identity group values into Superset roles. Map only the groups that match approved audiences. Verify by removing a test user from the identity provider group and confirming their next Superset sign-in is refused.
SECRET_KEY and rotation
Superset will not start without a user-specified SECRET_KEY, a requirement added in version 2.1.0. Store the key in your secrets manager and inject it at deploy time, never in a checked-in config file. When rotating, set PREVIOUS_SECRET_KEY to the old value so data protected by the old key stays readable while you re-encrypt it. Verify by starting a test instance without the key and confirming it fails, then completing a rotation in staging.
PostgreSQL SCRAM authentication
Superset's connection to the DataStore uses a PostgreSQL login, and the verification method matters. Set password_encryption to scram-sha-256 and require SCRAM for the read-only role in pg_hba.conf, because SCRAM is the preferred method and PostgreSQL 18 deprecated MD5 password authentication in its favor. Reset the read-only password after changing the setting so it is stored in the new format. Verify with SELECT rolname FROM pg_authid WHERE rolpassword NOT LIKE 'SCRAM-SHA-256$%';, which should return no Superset logins.
Network and TLS controls
Only the Superset application hosts should reach the DataStore's PostgreSQL port, and every connection should require TLS. Enforce this in the host firewall and in pg_hba.conf with a hostssl entry limited to the Superset network and the read-only role. Keep Superset's metadata database on separate infrastructure from the DataStore so dashboard definitions and credentials are not stored beside the data. Verify from a host outside the allowed range and with a non-TLS connection attempt, and confirm both are refused.
How to test the read path and the private resource boundary
Start by proving that the read path cannot write. Create the Superset database connection with the read-only datastore_default role, using the credentials behind ckan.datastore.read_url, then run statements from SQL Lab that the role must never be allowed to make: an INSERT, UPDATE and DELETE against a public DataStore table, plus a CREATE TABLE and an ALTER TABLE in the same schema. Each should fail with a permission error. Save the exact error text as your baseline for later runs. If any statement succeeds, stop and correct the grants before building charts, because Superset will store and display whatever that connection is able to do. Confirm the same privileges directly in PostgreSQL so the result does not depend on one client.
Next, test the private resource boundary from the query side. In SQL Lab, query the table behind a private resource by its physical table name and again by its alias view, and confirm that the read role gets a permission error or a missing relation both times. Then pick one public resource and compare row counts. Run SELECT count(*) against the Superset view, then call the Data API datastore_search action for the same resource ID with limit set to 1 and read the total field. The two counts should match. A mismatch can point to a view filter, a partial load or a stale refresh, so check the resource's load status in CKAN before you change the dashboard. Keep the resource IDs, view names and counts in your test record.
Last, test what a visibility change does. Switch a dataset from public to private in CKAN, then reload the affected Superset chart and check whether its data still returns. Because access in Superset follows PostgreSQL grants on the view, the chart should keep its current results until the view grants change. Repeat the check in the other direction, then record the result as an operating rule: the CKAN visibility setting alone does not expose or hide data in Superset. Repeat the full set after each CKAN upgrade, each Superset upgrade and each PostgreSQL minor update. Run those repeats in staging first, following the Superset upgrade guide and checking its breaking-change notes before production.
Common failures when Apache Superset reads the CKAN DataStore
This table lists common failures when Superset reads CKAN DataStore tables, with the likely cause and what to confirm for each. Read it from the top when a connection, login or query breaks, since the first rows cover network, credentials and grants before data availability. The main takeaway is that most access problems trace back to the read-only role, its grants and the view behind each resource.
| Failure | Likely cause | Fix to confirm |
|---|---|---|
| Test connection fails | Superset cannot reach the DataStore host or port, or its TLS settings do not match the server certificate | Confirm the host, port and sslmode in the read URL, and that the Superset host trusts the server certificate chain. |
| Authentication fails | Superset connects with the write owner or a mistyped password for the read-only datastore_default role | Connect only as the read-only role and confirm its password matches the one set during DataStore setup. |
| Permission denied on a view | Each DataStore resource alias is a view, and a view created after setup has no grant for the read-only role | Grant SELECT on the new view to the read-only role, then rerun the chart query from Superset to confirm access. |
| Resource missing in Superset | The XLoader load failed or no DataStore view exists, so there is no table to map | Check the resource's load status in CKAN and confirm the alias appears in the DataStore table metadata before mapping it. |
| Private table visible in dashboards | The read-only role can read tables for private CKAN datasets, so Superset skips CKAN's dataset access checks | Limit grants to views for public resources only, and review which datasets feed public dashboards. |
| Dashboards slow or stale | Charts run unfiltered queries over full tables, or cache timeouts keep old results longer than the source changes | Add filters and row limits to chart queries, and set cache timeouts that match how often the resource is reloaded. |
| Superset fails to start after upgrade or secret rotation | SECRET_KEY is missing from the configuration Superset loads, and Superset requires it to start | Set SECRET_KEY in the configuration or environment; during rotation, keep the old key in PREVIOUS_SECRET_KEY. |
| Metadata database version mismatch | The Superset metadata database runs a PostgreSQL version outside the range Superset documents | Use PostgreSQL 10 to 17 as listed in Superset's configuration docs. PostgreSQL 14 support ended November 12, 2026. |
What connecting Apache Superset to CKAN data costs and needs from your team
What drives the cost of connecting Superset to CKAN data?
The cost follows the scope of what you expose, since Superset itself has no paid edition. The main drivers are the number of views to approve, grant and network design, Superset identity integration, the number of dashboards built on those views, and the PostgreSQL version work and testing needed before go-live. Each view needs a reviewed definition, a read-only grant to the read-only database user and a decision about which hosts can reach the database. Identity integration adds effort when Superset users must map to CKAN organizations or roles. Dashboard count matters because each dashboard needs its own query review, filter logic and acceptance testing. Your own staff time is a cost too, mainly for the database administrator and the identity owner. Ask any partner for a quote that lists views, dashboards, network paths and identity work as separate line items, with the PostgreSQL test plan stated.
Can our own team connect Superset to CKAN without a partner?
Yes, for a small set of public views, if you have a Superset admin and a database administrator who can create views and grants. That path covers one schema, a handful of public resources and a clear read-only boundary. It gets harder when resources are private, when Superset users must be mapped to CKAN identities, or when several teams share dashboards with different access needs. In those cases the hard part is deciding who may see which rows, and that decision needs an identity owner and a documented review. Check whether your Superset admin has time to maintain the view definitions after go-live, because a change to a CKAN resource can break a view that a dashboard depends on. If any of these conditions apply, get a written scope from a partner before you commit internal staff to the build.
How long does it take to connect Superset to CKAN data?
Timing follows the scope agreed in writing before work starts, and no duration applies until that scope is fixed. The schedule depends on how many views need review, whether private resources are in scope, how many dashboards depend on those views, and when your database administrator and identity owner can make changes. Network paths between the Superset host and the PostgreSQL server can be the slowest step to approve, so raise them early. Testing also takes time, especially if you plan a PostgreSQL major version change alongside the connection. Ask for a written timeline that names each dependency on your side and the date each one is expected to close.
What do we need to provide for a Superset to CKAN connection?
The work needs four inputs from your side before it starts, and each one should have a named owner who can make decisions during the engagement:
- Database access for a database administrator who can create views, grants and network rules on the PostgreSQL server that hosts the DataStore.
- CKAN configuration access so the team can confirm the read and write settings in
ckan.datastore.read_urlandckan.datastore.write_urland review which resources are exposed. - A resource inventory that lists each DataStore table, its owner, its visibility and the dashboards planned on it.
- An identity owner who decides how Superset users map to CKAN organizations or roles.
If any of these owners is unavailable, the build will wait, so confirm their availability before you agree on a timeline.
Does Superset enforce CKAN private dataset rules directly?
No. Superset has no native mapping to CKAN's private dataset permissions, so the boundary has to be built in the database layer through views, grants and the read-only database user. Private resources should stay out of any view granted to Superset's database connection, and dashboards should query only views approved for their audience. Superset's roles and dashboard access settings control who opens a dashboard, but nothing in Superset reads the CKAN private flag or knows which dataset a table came from. The CKAN DataStore documentation describes the read-only user that the boundary depends on. Treat every change to a resource's visibility as a change that also requires a matching change to the view and grant, and ask for a test that proves a private row cannot be returned through Superset.
What happens to the Superset and CKAN connection after go-live?
Ongoing work covers Superset and PostgreSQL upgrades, and each upgrade is followed by a retest of the views, grants and dashboards. A Superset upgrade calls for a backup of the metadata database, running superset db upgrade and superset init, a staging test first and a check of UPDATING.md for breaking changes. PostgreSQL minor releases replace executables and need a restart, while major upgrades need a planned method and their own retest. CKAN upgrades can also change DataStore tables, so schema changes need review before they reach dashboards. Upgrade, support and continuous testing retainers are available, and their scope is agreed in writing.
What should a quote for this integration include?
A useful quote lists the work as separate items, with each item tied to a deliverable you can check. Most engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts. DeployOpen does not publish a price list, so the quote follows from that written scope. Ask for the number of views and dashboards in scope, the network and grant design, the identity mapping work, the PostgreSQL test plan and the handover and retest steps. Ask which items are one-time, such as the initial build, and which recur, such as upgrade retests or a retainer. Confirm whether private resources are included and how the quote changes if the resource inventory shifts during the build.
How DeployOpen scopes and delivers the Superset and DataStore connection
DeployOpen treats the Superset and DataStore connection as a scoped integration inside your own infrastructure. The work starts with a written scope that names the datasets, resources and dashboards in play, and the access model that governs them. Delivery covers the read-only database connection, the dashboard build, documentation and handover, with ongoing support available as a retainer.
How we scope
- The written scope lists which DataStore resources and tables Superset may read, and which stay out.
- Access is agreed up front: the read-only
datastore_defaultrole, dashboard owners and Superset roles. - Fixed-scope engagements mean deliverables and timelines are agreed in writing before work starts.
How we build
- Map each DataStore resource to a Superset dataset, using the read-only connection from
ckan.datastore.read_url. - Keep private resources out of public dashboards by filtering at the database and Superset role levels.
- Set the Superset SECRET_KEY, metadata database and OAuth or LDAP group mapping before any dashboard is shared.
How we hand over
- Documented connection settings, role definitions, dataset mappings and the list of excluded resources.
- Backup steps for the Superset metadata database, plus the upgrade runbook for future Superset releases.
- Walkthrough with your team on dashboards, access checks and what to review after each DataStore change.
How we support
- Optional retainer for ongoing support, Superset upgrades and retesting after CKAN or DataStore changes.
- Superset upgrades follow a back-up, staging test and database upgrade sequence, checked against
UPDATING.md. - Access reviews of Superset roles and DataStore grants, repeated on a schedule your team sets.

