Skip to content
Browse docs

Connecting to ClickHouse on Layerbase Cloud

ClickHouse instances expose HTTP and client-compatible endpoints for columnar analytics workloads.

Best for: Event analytics, logs, metrics, product analytics, and high-volume analytical queries.

1

Open your database in the dashboard

Go to /cloud, click the database you just created, and the connection panel shows the host, port, username, password, and a ready-to-paste connection string for the engine.

Use the generated username and password or token shown in the dashboard.

You can also download the whole set instead of copying values one at a time: the Connect dialog offers a Download .env file, ready to drop into a project under the environment variable your engine's clients expect, and a Download .txt with the labeled parameters. Both files contain the password in plain text, so keep them out of version control.

2

TLS is required, on by default

Use the https:// endpoint from Quick Connect.

ClickHouse HTTP endpoint over HTTPS

3

Use any standard client

ClickHouse works with the normal client family for that engine. Start with the dashboard snippet, then move the same URL and credentials into your app environment.

If your client has separate direct, pooled, TLS, or HTTP options, prefer the exact variant shown in Quick Connect.

bashClickHouse
curl -u layerbase:password "https://your-host.cloud.layerbase.dev/?query=SELECT%201"

ClickHouse notes

  • ClickHouse can take longer to provision than smaller engines.
  • For BI tools, copy the host and credentials exactly from Quick Connect.