---
title: "Trade secrets: How Coinhall uses ClickHouse to power its blockchain data platform"
description: "Coinhall, an omnichain trading terminal aggregating swap data from 23 blockchains, moved from BigQuery (about 2-second queries, thousands of dollars per month) to QuestDB and then to self-hosted ClickHouse."
url: "https://swe.quest/articles/trade-secrets-how-coinhall-uses-clickhouse-to-power-its-blockchain-data-platform-a19f7fb99396fe78"
canonical: "https://clickhouse.com/blog/trade-secrets-how-coinhall-uses-clickhouse-to-power-its-blockchain-data-platform"
source: "ClickHouse"
published: "2024-08-14"
difficulty: "easy"
kind: "Case study"
reading_minutes: 5
tags: ["analytics","databases","performance","cost-optimization"]
---

# Trade secrets: How Coinhall uses ClickHouse to power its blockchain data platform

A post on [ClickHouse](https://swe.quest/sources/clickhouse.md), published 2024-08-14, 5 min read, Case study. Original: [https://clickhouse.com/blog/trade-secrets-how-coinhall-uses-clickhouse-to-power-its-blockchain-data-platform](https://clickhouse.com/blog/trade-secrets-how-coinhall-uses-clickhouse-to-power-its-blockchain-data-platform)

## Summary

Coinhall, an omnichain trading terminal aggregating swap data from 23 blockchains, moved from BigQuery (about 2-second queries, thousands of dollars per month) to QuestDB and then to self-hosted ClickHouse. In Coinhall's comparison against Rockset, SingleStore and Snowflake, ClickHouse ran candlestick queries in 20 ms, latest-price queries in 8 ms and ASOF JOINs in 50 ms, on a 4 vCPU / 16 GB server costing about $50 a month. After migrating, the team tuned queries around sparse primary indexes and replaced full-table LIMIT BY scans with aggregating tables fed by materialized views. They also avoided or simplified sort-merge joins.

Written by swe.quest, not by the author.

**Difficulty:** Easy: no special background needed; explains what something is and why it matters

## Topics

- [Analytics & OLAP](https://swe.quest/tags/analytics.md) (Data & databases)
- [Databases](https://swe.quest/tags/databases.md) (Data & databases)
- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)
- [Cost optimization](https://swe.quest/tags/cost-optimization.md) (Reliability & operations)

## Prerequisites

- columnar OLAP databases ([easy posts on Analytics & OLAP](https://swe.quest/tags/analytics.md?difficulty=easy))
- SQL joins ([easy posts on SQL](https://swe.quest/tags/sql.md?difficulty=easy))

## Keywords

ClickHouse, BigQuery, QuestDB, Snowflake, SingleStore, Rockset, materialized views, Coinhall

## Related posts

- [Join me if you can: ClickHouse vs. Databricks vs. Snowflake - Part 1](https://swe.quest/articles/join-me-if-you-can-clickhouse-vs-databricks-vs-snowflake-part-1-abef280c3cc66c97.md): ClickHouse · 2025-06-24 · Easy · 7 min read · Analytics & OLAP, Performance engineering, Query engines, Cost optimization
  ClickHouse Cloud ran a third-party, join-heavy coffee-shop star-schema benchmark (17 queries, originally built to compare Databricks and Snowflake) with no query rewrites or tuning, and came out faster and cheaper at every scale from 721 million to 7.2 billion rows.
- [HIFI’s migration from BigQuery to ClickHouse](https://swe.quest/articles/hifi-s-migration-from-bigquery-to-clickhouse-5318550bbb72f66e.md): ClickHouse · 2023-01-09 · Medium · 8 min read · Analytics & OLAP, SQL, Databases, JavaScript
  HIFI moved music royalty analytics from BigQuery to ClickHouse because BigQuery's per-query pricing discouraged exploratory use and slot reservations didn't fit a startup's shifting workloads.
- [Join me if you can: ClickHouse vs. Databricks vs. Snowflake - Part 2](https://swe.quest/articles/join-me-if-you-can-clickhouse-vs-databricks-vs-snowflake-part-2-66aede87450dc5eb.md): ClickHouse · 2025-06-25 · Medium · 8 min read · Analytics & OLAP, Performance engineering, Query engines, SQL
  Replacing fact-to-dimension joins with in-memory dictionaries in ClickHouse Cloud sped up a 17-query join benchmark over 1.4 billion rows by 1.9–3.5× in total runtime, up to 6.6× on individual queries, and cut cost by up to 60%.
- [DENIC Improves Query Times By 10x with ClickHouse](https://swe.quest/articles/denic-improves-query-times-by-10x-with-clickhouse-060ef54871f5e907.md): ClickHouse · 2022-05-10 · Medium · 9 min read · Analytics & OLAP, Query engines, SQL, Performance engineering, Databases
  DENIC, the .de registry, built its data science platform on ClickHouse after rejecting Hadoop and Spark as too costly to administer and cloud services for privacy reasons.
- [TPC-H for less than a cent: ClickHouse Cloud vs. Snowflake, Databricks, BigQuery, and Redshift](https://swe.quest/articles/tpc-h-for-less-than-a-cent-clickhouse-cloud-vs-snowflake-databricks-bigquery-e1c9aad2d347b55d.md): ClickHouse · 2026-06-02 · Easy · 6 min read · Analytics & OLAP, Performance engineering, Cost optimization, Query engines
  On TPC-H SF100 (100 GB, 866M rows, 22 join-heavy queries), a single 59-core Graviton3 ClickHouse Cloud node finished hot runs in 19.8s for $0.063.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
