ClickHouse vs TimescaleDB: picking an analytics database in 2026
Which analytics database earns its keep in 2026 when you have three engineers and a 2 vCPU VPS.
Your Grafana dashboard takes eleven seconds to load, the query behind it scans forty million rows, and the person who wrote it left three months ago. That’s usually the moment a small team starts googling “ClickHouse vs TimescaleDB” — right when the analytics database question stops being academic and starts blocking a release. I’ve shipped both to production on small teams, and the honest answer is less exciting than the benchmarks suggest.
Let me set the scene properly, because it changes the recommendation. This is written for a team of three to six engineers, mostly running on PostgreSQL, on a budget where a Rp500 ribu/bulan jump in the hosting bill is a real conversation. Not a data platform team at a unicorn. If that’s you, keep reading.
Comparison table
| Dimension | ClickHouse | TimescaleDB |
|---|---|---|
| What it is | Standalone columnar OLAP engine | PostgreSQL extension for time-series |
| Query speed (wide scans) | Excellent (vectorized, columnar) | Good (great after compression) |
| Point lookups / upserts | Weak (append-oriented) | Excellent (it’s Postgres) |
| Joins against dimension tables | Workable but awkward | Native, comfortable |
| Learning curve for a Postgres team | New engine, new SQL dialect | Almost none |
| RAM appetite | Hungry (8GB+ for comfort) | Modest (runs on 4GB) |
| Self-host cost (single node) | Rp400-700rb/bulan | Rp150-250rb/bulan |
| Backups & tooling | Its own story | pg_dump, existing tools carry over |
| Local hiring pool | Small | Large (anyone who knows Postgres) |
TimescaleDB: the boring choice that usually wins
TimescaleDB is a Postgres extension. That single sentence is most of the argument. Your schema stays. Your migrations stay. Your pg_dump cron on that VPS in a Biznet rack stays. The junior you hired last month who knows Postgres but has never heard of columnar storage can be productive on day one.
The core primitives are hypertables (transparently partitioned tables) and continuous aggregates (materialized rollups that refresh incrementally). Turn on compression and a table of event data shrinks dramatically while staying queryable. A SELECT time_bucket('1 hour', ts), count(*) FROM events WHERE ts > now() - interval '7 days' that used to crawl becomes fine.
Where it strains: very wide scans over hundreds of millions of rows, especially aggregations touching many columns. Timescale is still a row store underneath the compression, so a full-fat OLAP scan will eventually feel it. It also inherits Postgres’s write-amplification story — heavy update-in-place workloads on huge tables get expensive.
But here’s the thing most comparison posts skip. For a lot of Indonesian startups, “analytics” means a few dashboards, some retention cohorts, and maybe an internal admin panel. Tens of millions of rows, not tens of billions. TimescaleDB clears that bar without asking your team to learn a second database or babysit a second backup pipeline.
ClickHouse: the specialist you call when you actually need it
ClickHouse is a different animal — a purpose-built columnar OLAP engine with vectorized execution, and on the query shape it’s built for, it’s genuinely fast in a way that makes you double-check the numbers. Scan two hundred million rows, group by a couple of dimensions, get a sub-second answer. That’s the pitch, and the pitch is real.
The MergeTree engine family is the heart of it: data sorted by your chosen key, merged in the background, compressed hard by default. SummingMergeTree and AggregatingMergeTree let you pre-aggregate at write time, which is a different mental model from Postgres and takes a minute to internalize.
Now the parts the benchmarks bury. ClickHouse is append-oriented — updates and deletes are mutations, and they’re heavy operations you schedule, not fire off casually. Joins against dimension tables are workable but never as comfortable as a Postgres join; you learn to denormalize. It wants RAM, and if you underprovision it spills and slows or falls over. And the SQL is ClickHouse SQL, not standard Postgres, so some of your team’s instincts transfer and some quietly don’t.
Operationally it’s a second thing to run: its own backup approach, its own upgrade path, its own failure modes at 2am. On a three-person team, that’s not a footnote. That’s a person’s weekend.
Verdict
Reach for TimescaleDB when:
- You’re already on Postgres and the team’s ops experience is Postgres
- Your data is in the millions to low hundreds of millions of rows
- You need upserts, joins, or transactional writes alongside your analytics
- Predictable, cheap self-hosting matters — a 4GB VPS is enough
- Hiring is a factor: anyone who knows SQL can maintain it
Reach for ClickHouse when:
- A specific query over hundreds of millions of rows is genuinely too slow on Timescale, even after compression
- Your workload is append-heavy and scan-heavy — logs, events, clickstream, metrics at real volume
- You can budget the RAM (8GB+) and the operational attention a second engine demands
- Sub-second aggregation over huge tables is a product requirement, not a nice-to-have
Do neither yet if you haven’t tried plain PostgreSQL with a BRIN index on your timestamp column and a couple of materialized views. It carries more analytics load than people expect, and it’s zero new infrastructure. Earn the second database before you adopt it.
My actual recommendation for the team I described at the top: start on TimescaleDB, because it costs you almost nothing to adopt and keeps every tool you already know. Instrument your slow queries. The day one of them refuses to get fast on Timescale no matter what you do — and you’ll know, because you’ll have the numbers — that’s your signal to stand up a single ClickHouse node next to it and route just that workload there. Don’t pick the fast database. Pick the one your team can operate, and let the data tell you when to add the specialist.
Ditulis oleh Asti Larasati