raw_events. You can read it with ClickHouse SQL in three places. Every query reads only the current project.
There is no direct database connection, BI connector or scheduled export to your own warehouse. Use the Explorer or the MCP server to read rows. Contact support for a full data export.
The raw_events table
See common fields for every key in
context.
Read JSON fields
context and properties are JSON strings. Use the ClickHouse JSON functions:
Count correctly
- Exclude bots.
raw_eventskeeps bot rows. AddJSONExtractString(context, 'device') != 'bot'. - Remove retries. A client retry can store a row twice. Count events with
uniqExact(message_id). - Count visitors with
uniqExact(anonymous_id)andanonymous_id != ''. - Use the date range.
{{date_from}}and{{date_to}}follow the date range in the page header.
Rules
Queries are read-only: oneSELECT or WITH statement over raw_events and your own subqueries. Other tables, table functions and SETTINGS or FORMAT clauses are refused. See Explorer limits for the full list.
Related
- SQL Explorer guide
- Metrics for how the built-in reports count