Cube
An open-source, headless semantic layer where you define metrics and access rules once in code and expose them to BI tools, apps and AI agents through SQL, REST and GraphQL.
- GitHub stars
- 21k
- Last commit
- today
- Latest release
- v1.7.48
- Self-hosted
- Yes
- Hosted version
- Available

Cube Core is an open-source semantic layer. You describe your metrics, dimensions, joins and permissions a single time, as code, and Cube exposes that model through SQL, REST and GraphQL APIs to whatever sits downstream: BI tools, custom applications or AI agents. It is headless, meaning it ships no user interface of its own, which leaves you free to design the analytics experience your product needs.
The project argues that every BI tool already relies on a semantic layer to hide data complexity, but most are proprietary and tied to a single platform. Cube aims to make that layer reusable. It connects to any SQL data source, including warehouses such as BigQuery, Snowflake and Databricks, engines such as Amazon Athena and Presto, and application databases such as Postgres. A built-in relational caching engine delivers fast responses and high concurrency for API requests.
The core is written in Rust and JavaScript, and its license is listed as 'Other' on GitHub, so review the terms for commercial use. Cube can be self-hosted, and the company also offers Cube Cloud. It suits data teams building embedded analytics or wanting consistent metric definitions across tools.
Key features
- Metrics and dimensions defined as code
- SQL, REST and GraphQL APIs
- Headless design with no built-in UI
- Connects to Snowflake, BigQuery and Databricks
- Built-in caching engine
- Access rules for governed data
Pricing: Free forever plan for hobby projects. Starter costs $40 and Premium $80 per developer per month; Enterprise is custom via a demo request.

