---
url: 'https://altinity.com/webinarspage/showing-beautiful-clickhouse-data-with-the-altinity-grafana-plugin'
title: Showing Beautiful ClickHouse® Data with the Altinity Grafana Plugin
author:
  name: Cristina Munteanu
  url: 'https://altinity.com/author/cmunteanu/'
date: '2024-06-20T12:08:56-07:00'
modified: '2026-05-27T04:34:35-07:00'
type: post
summary: 'Learn how to visualize ClickHouse® data beautifully using the Altinity Grafana Plugin for ClickHouse®, the most popular ClickHouse plugin in the world with over 16 million downloads. This webinar covers installation, building time series and geographic dashboards with the on-time...'
categories:
  - Webinars
tags:
  - analytic performance
  - Backup
  - ClickHouse
  - ClickHouse Performance
  - cloud-native
  - Data Lakes
  - Grafana
  - Kubernetes
  - Open Source
  - webinar
image: 'https://altinity.com/wp-content/uploads/2024/05/Showing-Beautiful-ClickHouse-Data-with-the-Altinity-Grafana-Plugin.png'
published: true
---

# Showing Beautiful ClickHouse® Data with the Altinity Grafana Plugin

**Recorded**: June 20 @ 08:00 am PDT  
**Presenter**: Eugene Klimov, ClickHouse Software Engineer @Altinity, and Robert Hodges, CEO @Altinity

In this webinar, Altinity’s CEO, Robert Hodges, and Plugin Maintainer, Eugene Klimov, walk through the Altinity Grafana Plugin for ClickHouse®, covering its history, installation, dashboard creation, advanced query techniques, and the development roadmap.

Robert opens by introducing the plugin’s history: it began as a community project by Roman Karimov while he was at Vertamedia and was adopted by Altinity in late 2019. With over 16.6 million downloads, it is by far the most popular way to connect Grafana to ClickHouse. The most significant recent milestone was a complete rewrite from AngularJS to React, making it fully compatible with Grafana 10 and beyond.

The session covers installation on Ubuntu, Docker, and Kubernetes, with a pro tip that the plugin still carries the original `vertamedia-clickhouse-datasource` identifier in Grafana’s plugin registry even though Altinity now maintains and owns it. Robert demonstrates how to configure a data source connection using Altinity.Cloud public playground endpoint (which hosts the on-time airline dataset, among others) as the demo backend.

The live demo section shows a complete airline performance dashboard built on the on-time dataset, covering flights during 2020. Robert walks through the interactivity: zooming into the Southwest Airlines meltdown in early February 2020 to see how delays cascaded across their east coast network, and then using the heat map visualization to identify and isolate Hawaiian Airlines’ cancellation spike during the same period. The demo illustrates how quickly ClickHouse responds even on a modest demo server.

The technical content covers the three-pane dashboard editor (panel preview, query editor, and panel options), how to specify the timestamp column for time series data, how macros work, particularly `$timeSeries`, `$timeFilter`, and `$table`, and how the query inspector is used for debugging. Robert explains how `Format as` options differ between time series and tabular visualizations and why that distinction matters.

Advanced techniques covered include function macros, such as `$columns` for multi-series time series graphs with less code, the `$perSecond` macro for converting monotonically increasing counters to change rates, defining selection variables to drive filter dropdowns, using multiple queries in a single panel to build pie charts with a top-five-plus-rest structure, geographic visualizations using the Geomap plugin with latitude and longitude data joined from an airports table, and a brief introduction to ClickHouse’s built-in OpenTelemetry trace visualization in Grafana.

**Here are the slides:**

[Showing-Beautiful-ClickHouse-Data-with-the-Altinity-Grafana-Plugin-2024-06-20](https://altinity.com/wp-content/uploads/2024/06/Showing-Beautiful-ClickHouse-Data-with-the-Altinity-Grafana-Plugin-2024-06-20.pdf)[Download](https://altinity.com/wp-content/uploads/2024/06/Showing-Beautiful-ClickHouse-Data-with-the-Altinity-Grafana-Plugin-2024-06-20.pdf)

## Key Moments (Timestamps)

Key moments generated with AI assistance.

- 00:11 – Welcome and housekeeping

- 01:33 – Speaker introductions: Robert Hodges and Eugene Klimov

- 03:10 – Plugin history: from Vertamedia to Altinity, 16.6 million downloads

- 05:14 – Recent milestone: rewrite from AngularJS to React for Grafana 10

- 06:01 – Architecture: ClickHouse, Grafana, and how the plugin connects them

- 10:14 – Altinity.Cloud playground: demo data endpoint

- 10:47 – Installing Grafana and the Altinity Plugin on Ubuntu and Docker

- 13:21 – Connecting Grafana to ClickHouse: data source configuration tips

- 16:27 – Live demo: airline performance dashboard for 2020

- 22:42 – Demo: building the dashboard from scratch

- 23:06 – The three-pane editor: panel preview, query editor, panel options

- 25:01 – Defining the data source and timestamp column

- 27:05 – Editing queries: $timeSeries, $timeFilter, $table macros explained

- 28:46 – Using the query inspector to debug

- 31:19 – Basic dashboard tips: time series type, macros, and Format as setting

- 32:37 – Advanced technique: $columns function macro for multi-series graphs

- 34:50 – Advanced technique: selection variables for interactive dropdowns

- 35:51 – Advanced technique: multiple queries for pie charts

- 37:27 – Geographic visualization: Geomap with airport delay data

- 39:05 – Live edit: geographic dashboard walkthrough

- 43:27 – Roadmap and resources

- 45:24 – Q&A: x.509 authentication support

## Webinar Transcript

### [00:11] – Welcome and Housekeeping

**Robert:** Hello everyone and welcome to our webinar on showing beautiful ClickHouse® data with the Altinity Grafana Plugin. My name is Robert Hodges and I will be the main presenter today. I also have Eugene Klimov, the maintainer of the Grafana plugin, helping me, along with a couple of other colleagues in attendance.

Before we dive in, a few housekeeping details. This presentation is being recorded and we will distribute it along with the slides to everybody who signed up within about 24 hours. We also have plenty of time to take questions. You can put them into the Q&A box provided by the Zoom webinar, or just throw them into the chat. If questions are relevant to what I am talking about I will address them right there; otherwise we will catch them at the end.

---

### [01:33] – Speaker Introductions

**Robert:** I am Robert Hodges. I have been working on databases for a really long time, more than 40 years now. I use Grafana pretty regularly because it is such an important part of visualization, so it is a pleasure to play around with this and talk about it.

With me today is Eugene Klimov, who is our maintainer for both Altinity Backup for ClickHouse® and the Altinity Grafana Plugin for ClickHouse®. There are other people who work on both of them, but Eugene is principal engineer on this. He is also a major contributor to Altinity.Cloud.

Altinity is an enterprise provider for ClickHouse®. We let you run it anywhere: you can run it in our cloud, all by yourself, or in a nice middle ground where you run the data in your own cloud and we manage it remotely. We are responsible for a number of popular open-source projects related to ClickHouse, including the Grafana plugin we will be discussing today, the Altinity Kubernetes Operator for ClickHouse®, Altinity Backup for ClickHouse®, and a number of other projects you may already be using.

---

### [03:10] – Plugin History: From Vertamedia to Altinity

**Robert:** Let me give you a little history on the Altinity Grafana Plugin for ClickHouse® because many people who use it may not know how old it is and how popular it is. This started as a community project written originally by Roman Karimov. He is actually one of the founders of VictoriaMetrics, which is what he works on full-time, so he is very focused on observability. He started this project several years ago, right around the time ClickHouse was open-sourced. He was originally working at a company called Vertamedia, which is who owned the project to begin with. Roman moved on to another position, and he called us up and said, “Can you maintain this project?” That was in late 2019. We have been running and maintaining it ever since.

If you look at the code, Grafana plugins are a mix of Go and React. The UI is done in React. The part of the plugin that actually talks to the ClickHouse database is done in Go. This is surprisingly popular. The last time I checked, we had something like 16.6 million downloads, making it by far the most popular way to connect Grafana to ClickHouse. We use it in Altinity.Cloud, and for that reason, we are very interested in maintaining it. A lot of our customers also depend on it.

---

### [05:14] – Recent Milestone: Rewrite from AngularJS to React

**Robert:** The big recent development on this is that we rewrote it completely from AngularJS to React. Recent versions of Grafana changed the interface, and the old AngularJS-based implementations no longer work, or they generate heavy warnings and will eventually be disabled entirely. We completed that rewrite several months ago, so now we are set for Grafana 10 and beyond. We are continuing to do additional releases.

---

### [06:01] – How ClickHouse and Grafana Fit Together

**Robert:** For the one person on this call who has never heard of ClickHouse: it is a real-time analytic database, very popular for a wide range of use cases. Observability is probably the biggest use case today, but there is also web analytics, real-time marketing, real-time bidding for mobile ads, valuing securities in financial markets, network analysis of content delivery networks, and more. If it generates a lot of data and you need fast answers, that is a use case for ClickHouse. It is in many ways a mix of popular relational databases like MySQL in that it talks SQL, is open source, and runs practically anywhere, combined with features you would expect in an analytic database: columnar storage optimized for reads, extremely efficient parallel execution including SIMD instructions and parallel query across many network nodes, and the ability to scale to many petabytes.

Grafana is probably the most popular tool for operational metrics, particularly time series. It has wonderful visualizations, is very simple to install, supports a wide range of data sources, and is highly interactive. That interactivity is a really key feature, as we will see in the demo.

Here is how the two things fit together. You have a browser showing the visualizations. It talks to the Grafana service, which listens on port 3000 by default. That service has plugins. The Altinity Grafana Plugin for ClickHouse® has a React piece that provides the UI for working on dashboards and a Go implementation that contacts the ClickHouse server. The ClickHouse backend listens on port 8123 for HTTP access (unencrypted) and port 8443 for encrypted connections. In a production setting, you would use 8443. When you bring up a dashboard, the plugin sends a stream of queries to ClickHouse and typically gets very fast answers back.

---

### [10:14] – Altinity.Cloud Playground for the Demo

**Robert:** For the demo today we are using a [playground that we run in Altinity.Cloud](https://docs.altinity.com/altinitycloud/demo-cluster/). Anyone can access this endpoint. It has a number of data sets. The one we are going to use is the `ontime` data set, which has a couple hundred million rows of US airline on-time performance data. We will also use a table called `airports`, which gives us airport names and locations for geographic visualizations.

---

### [10:47] – Installing Grafana and the Altinity Plugin

**Robert:** Here is how to set up Grafana and the [Altinity Grafana Plugin for ClickHouse®](https://altinity.com/blog/using-altinitys-grafana-clickhouse-plugin-in-grafana-cloud) on Ubuntu. The commands add the Grafana repository, install the GPG key, and install Grafana. Once it is pulled down, you install the plugin using the Grafana CLI: `grafana-cli plugins install vertamedia-clickhouse-datasource`.

A pro tip here: the plugin is still labeled as `vertamedia-clickhouse-datasource` in Grafana’s plugin registry. The reason is that once you set a plugin name in Grafana’s system, you cannot change it. So even though the code is in our GitHub and when you go to it you will see it says the Altinity plugin and we maintain it fully, it still has the old Vertamedia name. Given the history of how the project started at Vertamedia, it makes sense and gives credit where it is due. Once you have installed the plugin, restart the Grafana service and you are off and running.

You can also set it up in Docker: just run a `docker run` command and it will pop right up. You can use Docker Compose if you prefer, and there is a Helm chart for deploying on Kubernetes. There are many ways to install it and you can take your pick.

---

### [13:21] – Connecting Grafana to ClickHouse

**Robert:** Once you have Grafana set up, point your browser to it, log in, and the first thing you will want to do is add a ClickHouse data source. Go to Connections in the menu, add a new connection, search for Altinity or ClickHouse, press the plugin tile, and if the plugin is not already installed you will see an install button. Just press it. After installation, Grafana drops you straight into the connection configuration screen.

A few important settings. Always use **server access** rather than browser access. While it is technically possible to issue Grafana queries from the browser, practically nobody does that. Going through the server gives you a level of indirection and avoids cross-site scripting limitations. Always use **POST** rather than GET. This makes it easier to see your queries in the debugger. Log in using basic auth with credentials.

If you are on an older version of Grafana (below version 10) or have an older version of the plugin, you may see a message saying it can only offer version 2.5.4 of the plugin, or you may see a warning about AngularJS plugins being deprecated. Both of these just mean you need to upgrade to the latest plugin version.

---

### [16:27] – Live Demo: Airline Performance Dashboard for 2020

**Robert:** Let me show you a sample dashboard I built that uses the Altinity.Cloud playground’s airline on-time database. When you first open it with the default time range of the last six hours, it appears empty because the data set does not include recent data. Let me change the time range to the year 2020, which is when COVID started and makes the airline data very interesting.

Within about a second all the data is populated. We have data covering all airlines during that era with really nice graphs.

Let me zoom in on Southwest Airlines, which in this dataset uses the carrier code WN. Selecting WN leaves the top of the dashboard unchanged (that is all-carrier data) but as we scroll down we can see Southwest specifically. Their overall on-time performance looks pretty good for most of the year, but there are spikes where they have very bad on-time performance and a lot of canceled flights. We can see the large cancellation spike right around the time COVID hit.

Now let me zero in on one of the points where Southwest had a lot of delayed arrivals. One of the really great things about Grafana is you can just highlight a section of any graph and it instantly zooms in. Now we can see this is one of those classic Southwest network meltdowns where a substantial portion of their flights became late and it cascaded across their network. Looking at this particular period in early February, we can see the cascading delays concentrated on the east coast of the United States while things were still pretty good for west coast flights.

Let me back up and look at the heat map visualization. We can use it to identify particular airlines that are interesting. For example, `HA` is Hawaiian Airlines. If I select HA and scroll down, sure enough we can see that during this time period Hawaiian Airlines had a bunch of canceled flights, which is exactly what shows up as a spike on the heat map.

This demonstrates the interactivity and shows the performance clearly. This is not a particularly strong demo server but ClickHouse gives really excellent response times, and a lot of the interactivity inside Grafana happens within the browser itself so it feels extremely fast.

---

### [22:42] – Building a Dashboard: The Three-Pane Editor

**Robert:** Let me walk through how to actually build one of these dashboards. When you start a fresh dashboard, you see a button labeled “Add visualization.” Press that, pick your data source, and then you are in the editor. The editor has three main parts.

The **panel preview** shows you what you are creating as you are editing it. The data updates in real time as you make query changes. The **query editor** lets you set the properties of the table and time series column you want to use, as well as the actual SQL query that fetches the data. The **panel options** panel on the right is where you choose the visualization type from a dropdown. We have “time series” selected here, but there are about 15 to 25 visualization types available in the open-source distribution, ranging from geographic data and flame graphs to pie charts and more.

---

### [25:01] – Defining the Data Source and Timestamp Column

**Robert:** When you go into the query editor, you can change the data source on the fly. You pick your database and then, because Grafana is mostly dealing with time series data, you need to give Grafana a hint about which column contains the time value.

Here is the setting: we are using type `datetime` for the time series column. In this particular data set, the column is called `FlightDate`, but it is actually of type Date, not DateTime. Grafana is not very happy with plain Date types for time series, so we wrap it in a `toDateTime()` conversion function. That is basically all you need to do, and then Grafana knows what you are talking about and can fetch and scale the data correctly.

---

### [27:05] – Editing Queries: The $timeSeries, $timeFilter, and $table Macros

**Robert:** In the SQL editor tab you can write raw SQL. You will notice items with dollar signs: these are macros. `$timeSeries` is a macro that automatically generates the correct timestamp bucketing expression for the time range selected in Grafana’s time picker. The macro takes care of making sure the output is formatted exactly the way Grafana expects: timestamps down to milliseconds with the correct time interval. `$timeFilter` sets your WHERE clause filters based on the date range currently selected in Grafana’s time picker. Both of these macros you will normally always use, because the code they generate is quite complex and something you really do not want to write yourself. `$table` is the table name picked in the query settings.

There is also a “Format as” setting, which controls how the data is presented back to Grafana. It defaults to “Time Series” for time series visualizations, but if you are building a table, geographic visualization, trace visualization, or other type, you need to change this accordingly. Grafana expects data in specific shapes for different visualization types, and this setting handles that mapping.

---

### [28:46] – Using the Query Inspector to Debug

**Robert:** A lot of time spent working with Grafana is in the debugger, technically called the query inspector. Grafana queries are a little bit finicky the first time you put them in, so you will frequently jump into the query inspector to see what is actually happening.

The query inspector has a refresh button that runs your current query and shows you the exact HTTP POST request being sent to ClickHouse, the response, and the individual data values that come back. If there are errors you can see them. You can also see the exact data and confirm yes, these are the values I expect.

The most important tab in the query inspector is the **Data** tab. This shows you the data that is actually arriving at your visualization. When debugging, make sure you are getting results back with no errors and that something is showing up in the Data tab. Once that is confirmed, it should start populating inside the visualization.

For deeper debugging, you can copy the SQL from the query inspector and run it directly against ClickHouse in your preferred client tool, such as DBeaver. For read access, you typically just need SELECT permissions on the relevant tables. That is a much faster iteration cycle than trying to debug inside the Grafana UI.

---

### [31:19] – Basic Dashboard Tips Summary

**Robert:** A quick summary of the basics for time series graphs, which are among the most common. Set the visualization type to “Time Series.” Select the column that contains your time value. Use `toDateTime()` if your column is a plain Date type. Always use the `$timeSeries` and `$timeFilter` macros; they handle all the time range conversions automatically. And select “Time Series” in the Format as setting to make the data shape match what Grafana expects.

For all visualizations generally: add your query with macros in the editor, check the generated SQL using the “Show generated SQL” button, use the query inspector to debug, and for stubborn queries, copy them to your favorite ClickHouse client.

---

### [32:37] – Advanced Technique: $columns Function Macro

**Robert:** Here are a few advanced tricks. Function macros can help you write complex queries much more concisely. For example, if you want to graph the count of flights per airline carrier over time, you could write a fairly complex SQL query manually. Or you can use the [`$columns` macro](https://docs.altinity.com/altinitycloud/administratorguide/integrations/grafana/), which takes a column expression and an aggregate, and generates all the boilerplate GROUP BY and ORDER BY code for you. The resulting SQL is equivalent and significantly longer, but the macro source is much cleaner and reduces the chance of errors.

There are several macros in this family. The `$perSecond` macro is particularly useful for converting monotonically increasing counters, such as a cumulative count of HTTP requests or file descriptor opens, into a change rate. This is another calculation you really do not want to code yourself repeatedly.

---

### [34:50] – Advanced Technique: Selection Variables for Interactive Dropdowns

**Robert:** You saw in the demo that I was selecting individual airline carriers. Those dropdowns are called variables, and you set them up in the dashboard settings under the Variables tab. Press “New variable” and for each one you provide a query to go fetch the list of values and populate the dropdown. Once defined, these variables are available to use inside your SQL queries using the `$variable_name` syntax. You can also use them inside visualization titles, which is a nice touch.

---

### [35:51] – Advanced Technique: Multiple Queries for Pie Charts

**Robert:** It is often convenient or necessary to have multiple queries in a single panel. Here is a good example: you want to show a pie chart of each airline carrier’s share of total flights. The problem is that many carriers have very few flights and will just be tiny invisible slivers of the pie. So instead of one query, I use two. The first query fetches the top five carriers by flight count. The second query uses a SQL trick with `LIMIT 5, 1000` to skip the first five results and return all the remaining carriers grouped together as “other.” Both queries return data in the same shape, and Grafana unions them together to draw the pie chart. ClickHouse is so fast on this data set that running the same base query twice is not an issue.

---

### [37:27] – Geographic Visualization: Geomap with Airport Delay Data

**Robert:** One of the really fun visualization types in Grafana is the Geomap. Here is an example showing flight delays per US airport. Let me walk through how it is built.

The SQL query uses a subquery to scan the `ontime` table, compute delay percentages grouped by destination airport, and then join the result against the `airports` table to get the airport name, latitude, and longitude. This join pattern is a classic use of ClickHouse’s fast query engine: the subquery does the heavy lifting on the large `ontime` table, and the join against the smaller `airports` reference table adds the location data.

There is one important thing to note here: **Format as Table**, not Time Series. This is geographic data, not time series data, so we have to tell Grafana that. This ensures the data is passed to the Geomap visualization in the right shape.

In the panel options, I selected the **Geomap** visualization type from the dropdown. Because I named my columns `latitude` and `longitude` (which Grafana recognizes automatically), the plugin connected them to the map without any additional mapping configuration. I did have to configure thresholds manually: I set 10% delayed flights to turn an airport yellow and 20% to turn it red, since Grafana’s default threshold of 80% would not be meaningful for airline delay data. The size of each airport’s blob is based on the number of flights passing through it.

This shows how you can build a really compelling geographic visualization by combining ClickHouse’s ability to do fast aggregations on large tables with Grafana’s Geomap.

---

### [38:53] – Brief Note: ClickHouse OpenTelemetry Trace Visualization

**Robert:** One more interesting capability worth mentioning: ClickHouse now has the ability to automatically generate OpenTelemetry-style trace spans for its own internal operations. You have to enable this in `config.xml`. Once enabled, ClickHouse puts all query spans into the `system.opentelemetry_span_log` table. You can then display these inside Grafana using the Trace visualization type. Eugene put together a nice example of this. It is a somewhat new capability in Grafana but available and quite useful for understanding ClickHouse query execution.

---

### [43:27] – Roadmap and Resources

**Robert:** We are actively developing the plugin. Things on the [roadmap](https://docs.altinity.com/releasenotes/altinity-grafana-release-notes/) include streaming support, additional improvements and bug fixes, performance improvements, and an extended library of dashboard visualization examples. We use this constantly but we have not had a nice visualization library in the past. We are working on that, and it will include the kind of dashboard example we have been playing around with today.

This is completely open source under the MIT license. If you see a problem, go ahead and log an issue. That helps us know what to work on next. If you have got a solution, submit a pull request. We love them.

For more information, check out the Altinity blog, and come meet us on Slack. There is an Altinity Slack channel accessible from the Slack icon on the upper right of our website. You can also set up a call if you have questions about ClickHouse support or specific things you would like to accomplish.

---

### [45:24] – Q&A: x.509 Authentication

**Robert:** On the question about x.509 authentication and mutual TLS: yes, the plugin should support this. It is based on standard HTTP requests using the Go HTTP library, and the underlying Go library supports standard certificate-based authentication. Eugene confirms that x.509 is supported precisely because under the covers we are just doing HTTP requests, so the full standard set of features that the Go HTTP library supports is available.

Thank you all for joining today. A huge thank you to Eugene Klimov for supporting this project and getting the React rewrite done. Thank you also to Doug Tidwell for documentation and to Josh Lee, our developer advocate, for help on this presentation. You will receive copies of the slides and the recording shortly. Thanks again and have a great day.

---

## FAQ Section

**Q: What is the Altinity Grafana Plugin for ClickHouse and how is it different from the Grafana-maintained ClickHouse plugin?**

A: The Altinity Grafana Plugin for ClickHouse® was originally created by Roman Karimov at Vertamedia in 2017 and has been maintained by Altinity since late 2019. With over 16.6 million downloads, it is the most popular ClickHouse plugin in Grafana’s plugin library. It is built with a Go backend for communicating with ClickHouse over HTTP and a React frontend. Its key differentiator is a powerful set of macros, including `$timeSeries`, `$timeFilter`, `$table`, `$columns`, and `$perSecond`, that generate complex boilerplate SQL automatically and make it much easier to build common analytics visualizations. The Grafana-maintained ClickHouse plugin is also a capable option, particularly for OpenTelemetry trace visualization, but the Altinity plugin is generally preferred for broad ClickHouse analytics workloads.

**Q: What are Grafana macros in the context of the Altinity plugin, and why should I use them?**

A: Macros are shorthand expressions that the Altinity plugin expands into full SQL code before sending a query to ClickHouse. The most important ones for time series work are `$timeSeries`, which generates the correct timestamp bucketing expression for whatever time interval Grafana has selected; `$timeFilter`, which generates the WHERE clause conditions that match the time range picker; and `$table`, which refers to the table you selected in the query settings. These macros save you from writing verbose and error-prone timestamp conversion code manually and ensure your queries stay in sync with Grafana’s time picker automatically. Function macros like `$columns` go further, generating entire GROUP BY structures for multi-series time series graphs from a compact expression.

**Q: How do I debug a Grafana query that is not working?**

A: Use the Grafana query inspector, which you can open from any panel in edit mode. Click the refresh button to run your query and see the full HTTP POST request, the response, any error messages, and the actual data values returned. The most important tab is the Data tab, which shows exactly what data is arriving at your visualization. If you see data there with no errors but the panel still looks wrong, the issue is usually the “Format as” setting or a mismatch in column names. For complex SQL that is hard to debug inside Grafana, copy the generated SQL from the query inspector and run it directly in your ClickHouse client tool of choice, such as DBeaver. Iterating on queries in a direct ClickHouse client is much faster than going through the Grafana UI.

**Q: How do I build a geographic visualization with ClickHouse and Grafana?**

A: Use the **Geomap** visualization type. Your SQL query needs to return columns named `latitude` and `longitude` (which Grafana recognizes automatically) along with whatever value you want to display. A common pattern is to join your large analytics table against a smaller reference table that contains coordinates, such as an airports table. Set “Format as” to “Table” rather than “Time Series” in the query settings, since geographic data is not time series data. In the panel options, select [Geomap](https://beta.docs.altinity.com/integrations/clickhouse-and-grafana/grafana-create-charts/) and configure thresholds to control the color coding of the data points. The size and color of each point can be driven by different numeric columns from your query result.

**Q: Can I use the Altinity Grafana plugin to visualize ClickHouse’s internal OpenTelemetry traces?**

A: Yes. ClickHouse has built-in support for generating OpenTelemetry-compatible trace spans for its own query execution. You enable this in `config.xml`, after which ClickHouse stores all query spans in the `system.opentelemetry_span_log` table. You can visualize these spans in Grafana using the Trace visualization type and the Altinity plugin. This gives you deep visibility into ClickHouse’s internal query execution, including query parsing, planning, execution steps, and for distributed queries, the communication between nodes.

---

*© 2026 Altinity, Inc. All rights reserved. Altinity®, Altinity.Cloud®, and Altinity Stable® are registered trademarks of Altinity, Inc. ClickHouse® is a registered trademark of ClickHouse, Inc.; Altinity is not affiliated with or associated with ClickHouse, Inc. Kubernetes, MySQL, and PostgreSQL are trademarks and property of their respective owners.*

