Skip to main content
Seasoned ⭐️⭐️
August 24, 2026
Question

How to add Timeseries Target Unit to the label in Grafana

The latest version of the Grafana connector supports unit conversion when CogniteUnit is defined. 
However, I’m not able to add the target unit to the label. I can add the defined unit using {{unit}}. Using the “Query Inspector” I see that the target unit is returned in the data object via the unitExternalId, but I cannot display it using {{unitExternalId}}. 

 

 

Resulting legend

 

Query inspector results

I notice that some of the properties can be shown, like type and isStep, but I assume it is because I get it directly from the timeseries instance?

Any suggestions to how we can add the target unit (without having to manually write it to the label)?

1 reply

danielferraz
Expert ⭐️⭐️⭐️⭐️
Expert ⭐️⭐️⭐️⭐️
August 25, 2026

Hi Gunnar.
We just shipped a fix for this in the Grafana connector. You'll be able to use {{unit.symbol}} or {{unit.name}} in the label field, and it'll resolve against the target unit if selected, otherwise the storage unit. {{unitExternalId}} directly won't work, but {{unit.externalId}} should do the trick.

The release should be out within (at most) the next couple of weeks, we'll update this thread when it's live!