User matching: Opal matches ClickHouse users to Opal accounts by email. If
the user’s email in Clickhouse does not match the user’s email in Opal, the
account will appear as unlinked and can be manually associated through
Clickhouse.
- Users can request access to ClickHouse roles, databases, and tables directly from Opal, with time-limited grants that expire automatically
- Admins can import ClickHouse resources into Opal’s catalog, configure reviewers, and see a full audit trail of who has access to what
- Admins can revoke access manually at any time — the change is applied immediately in ClickHouse
Supported resources
| Resource | Read | Grant and revoke access |
|---|---|---|
| ClickHouse Database | ✔️ | ✔️ |
| ClickHouse Table | ✔️ | ✔️ |
| ClickHouse Role | ✔️ | ✔️ |
| ClickHouse User | ✔️ |
Requirements
To connect ClickHouse to Opal, you must first:- Be an Opal Admin
- Have access to a running ClickHouse instance in ClickHouse Cloud
- Have credentials for a ClickHouse admin user able to create new users and grant permissions
1. Create a service account in ClickHouse
Opal requires a dedicated service account in ClickHouse with read access to system tables and permission to manage grants. In your ClickHouse SQL Console (or viacurl), run:
You must use
GRANT CURRENT GRANTS(ACCESS MANAGEMENT ON *.*) instead of
GRANT ACCESS MANAGEMENT. This is because the Cloud default user doesn’t
hold the full ACCESS MANAGEMENT bundle, so CURRENT GRANTS passes only the
subset needed by Opal.2. Add Clickhouse to Opal
In Opal, go to Inventory > + App, then select ClickHouse. Fill in the connection form using the following details.| Field | Where to find it | Example |
|---|---|---|
| Hostname | ClickHouse Cloud → your service → Connect tab | abc123.us-east-1.aws.clickhouse.cloud |
| Port | Always 8443 on ClickHouse Cloud (HTTPS) | 8443 |
| Use TLS | Always enabled on ClickHouse Cloud | - |
| Username | The service account created in step 1 | opal_service |
| Password | The password set for the service account in step 1 |
3. Import resources
After the connection is created, Opal will run an initial sync to discover your ClickHouse databases, tables, roles, and users. Go to Assets to see everything that was discovered. To make a resource or role requestable, import them and configure reviewers and access policies as needed.Only imported resources with “Allow Requests” toggled ON will appear in Opal’s Request Access catalog.

