02 Single Values
Single value and stat panels in Grafana.
What You'll Learn
Create Stat panels for prominent value display
Use Gauge panels for visual range indication
Build Bar Gauge panels for comparing multiple values
Configure thresholds for colour-coded status
Choose the right calculation for your use case
Prerequisites
Completed Tutorial 1.2: Your First Dashboard
Understanding of basic panel creation
Overview
Single value displays show one or more values prominently, making them ideal for:
Current status at a glance β Is the machine running? What's the current temperature?
KPI dashboards β Display OEE, throughput, or production counts
Shopfloor monitors β Large, visible numbers for operators
Alert-style indicators β Red/yellow/green status based on thresholds
Grafana offers three main single-value visualization types:
Stat
Large numbers with optional sparkline
Gauge
Values within a defined range
Bar Gauge
Comparing multiple values side by side
Stat Panel
The Stat panel displays values as large, prominent numbers β perfect for dashboards viewed from a distance.
Creating a Stat Panel
Add a new panel to your dashboard
Select your data source and configure your query
In the visualization dropdown (top right of panel editor), select Stat
[SCREENSHOT: Visualization type selector with Stat highlighted]
The panel now displays your value as a large number
Stat Panel Options
Value Calculation
The Reduce options determine what value is displayed:
In the right sidebar, find Value options
Set Calculation to one of:
Last *
Most recent non-null value
Current status (most common)
Last
Most recent value (may be null)
Real-time monitoring
Mean
Average over time range
Typical operating value
Max
Maximum value
Peak detection
Min
Minimum value
Low point detection
Sum
Total of all values
Production counts
[SCREENSHOT: Calculation dropdown in value options]
Colour Mode
Controls what element displays the threshold colour:
Value
The number itself is coloured
Background
The panel background is coloured
Background (gradient)
Gradient background based on value
None
No threshold colouring
[SCREENSHOT: Stat panel colour mode comparison - Value vs Background]
Tip: Use Background for shopfloor displays β it's visible from further away.
Graph Mode
Optionally show a sparkline (mini chart) behind the value:
None
Value only
Area
Sparkline with filled area
[SCREENSHOT: Stat panel with Area sparkline vs None]
Tip: Sparklines show trend at a glance but can be distracting on busy dashboards.
Text Mode
Controls what text is displayed:
Auto
Value and name
Value
Value only
Value and name
Both explicitly
Name
Name only (useful with background colour)
None
No text
Orientation
When displaying multiple values:
Auto: Grafana chooses based on panel dimensions
Horizontal: Values side by side
Vertical: Values stacked
Gauge Panel
Gauges display values on a circular arc, showing where the value falls within a range.
Creating a Gauge Panel
Add a new panel and configure your query
Select Gauge as the visualization type
[SCREENSHOT: Gauge panel example]
Gauge Panel Options
Min and Max
Define the range of your gauge:
In Standard options, set Min and Max values
These define the start and end of the gauge arc
[SCREENSHOT: Min/Max settings in standard options]
Example: For a temperature sensor:
Min: 0
Max: 300 (Β°C)
Threshold Markers
Show threshold levels on the gauge:
Find Gauge section in the sidebar
Enable Show threshold markers
Optionally enable Show threshold labels to display values
[SCREENSHOT: Gauge with threshold markers and labels]
Orientation
Auto: Based on panel shape
Horizontal: Gauge arcs arranged horizontally
Vertical: Gauge arcs stacked vertically
Bar Gauge Panel
Bar Gauges display values as horizontal or vertical bars, excellent for comparing multiple values.
Creating a Bar Gauge Panel
Add a new panel and configure your query (select multiple variables)
Select Bar Gauge as the visualization type
[SCREENSHOT: Bar Gauge panel with multiple values]
Bar Gauge Options
Display Mode
Gradient
Smooth colour gradient (modern look)
Retro LCD
Segmented display (industrial look)
Basic
Solid colour bars
[SCREENSHOT: Bar Gauge display mode comparison]
Tip: Use Retro LCD for an industrial control panel aesthetic.
Orientation
Horizontal
Bars extend left to right
Vertical
Bars extend bottom to top
[SCREENSHOT: Horizontal vs Vertical bar gauge]
Show Unfilled Area
When enabled, displays the "empty" portion of the bar in a muted colour, showing the full range.
Value Display
Value colour
Text matches bar colour
Text colour
Text uses theme colour
Hidden
No value text
Name Placement
Auto
Based on orientation
Top
Above the bar
Left
To the left of the bar
Configuring Thresholds
Thresholds are essential for single-value displays β they provide instant visual feedback about whether values are normal, warning, or critical.
Adding Thresholds
In the right sidebar, find Thresholds
Click + Add threshold
Enter a value and select a colour
[SCREENSHOT: Threshold configuration panel]
Threshold Example: Temperature Monitoring
Base
Green
Normal operation
250
Yellow
Warning β approaching limit
300
Red
Critical β action needed
Threshold Modes
Absolute
Fixed values (e.g., turn red at 100)
Percentage
Relative to min/max (e.g., turn red at 90%)
Tip: Use Absolute when you have known limits (max pressure = 500 bar). Use Percentage when comparing values with different scales.
Threshold Colour Application
For single-value panels, thresholds automatically colour the value or background based on your Colour mode setting.
Value Mappings
Value mappings let you display text instead of numbers for specific values.
Creating Value Mappings
In the sidebar, find Value mappings
Click Add value mapping
Choose a mapping type:
Value
Exact match (1 β "Running")
Range
Numeric range (0-10 β "Low")
Regex
Pattern match
Special
Null, NaN, etc.
Example: Machine Status from Line Speed
Use the machine's line speed to determine its production status. This approach works well for shopfloor displays where operators need to see machine state at a glance. Here, we use an exact match with 0 to classify the machine as standing and everything above 1 as running. Depending on the underlying variable it might be useful to use a range for the downtime classification too i.e. [0-1].
Configuration:
[SCREENSHOT: Configuration]
Recommended panel settings:
Colour mode
Background (solid)
Easy to identify from a distance
Text mode
Value
Shows the status
[SCREENSHOT: Machine status stat panel with value mapping - showing green "IN PRODUCTION" background]
Tip: Depending on your variable, consider using a range instead of an exact value for the downtime condition. For example, if your line speed fluctuates slightly and never reaches exactly 0, map the range 0β1 to "DOWNTIME" instead.
Practical Examples
Example 1: Current Throughput (Stat)
A large display showing current production rate:
Visualization
Stat
Calculation
Last *
Colour mode
Background
Graph mode
Area
Thresholds
Red (base), Green (200), Red (400)
[SCREENSHOT: Throughput stat panel with background colour and sparkline]
Example 2: Pressure Gauge
A gauge showing current pressure with safe operating range:
Visualization
Gauge
Min
0
Max
500
Thresholds
Green (base), Yellow (400), Red (450)
Show threshold markers
Yes
Unit
Pressure (bar)
[SCREENSHOT: Pressure gauge with threshold markers]
Example 3: Multi-Extruder Comparison (Bar Gauge)
Comparing throughput across multiple extruders:
Visualization
Bar Gauge
Variables
Extruder A, B, C Durchsatz
Orientation
Horizontal
Display mode
Gradient
Show unfilled
Yes
[SCREENSHOT: Bar gauge comparing three extruder throughputs]
Choosing the Right Visualization
Show one prominent value
Stat
Show value within a range
Gauge
Compare multiple similar values
Bar Gauge
Show trend alongside value
Stat with sparkline
Industrial control panel look
Bar Gauge (LCD mode)
Maximum visibility from distance
Stat with background colour
Tips and Best Practices
For Shopfloor Displays
Use Stat with Background colour mode
Set large panel sizes
Use high-contrast colours (green/red or blue/orange for a colourblind friendly design)
Keep text minimal β let colours communicate status
For KPI Dashboards
Use consistent thresholds across similar metrics
Group related gauges together
Include units in the display
Consider sparklines to show trend
For Mobile Dashboards
Use Stat panels (most readable at small sizes)
Avoid gauges (too much detail for small screens)
Stack panels vertically
Performance Tips
Stat panels render faster than gauges
Limit sparkline time range for better performance
Use Last * calculation (faster than aggregations)
Summary
You've learned how to create effective single-value displays:
Stat panels for prominent numbers with optional sparklines
Gauge panels for range visualization
Bar Gauge panels for multi-value comparison
Thresholds for colour-coded status
Value mappings for text display
What's Next?
Continue learning about visualization types:
Tables β Displaying data in tabular format
Advanced Styling β Units, overrides, and more
Last updated