Repository navigation
Tile Feature

A Chartdeck chart for Home Assistant's tile card: a small sparkline, a row of columns or a bar in the strip under the tile, where the tile's own features (a brightness slider, a fan speed) go. It comes with the card; there is nothing more to install.
A trend under a sensor's tile, a plug's power under the tile of the switch that controls it, the last day of a room's temperature under its thermostat.
type: tile
entity: switch.kettle_plug
features:
- type: custom:chartdeck-feature
style: sparkline
entity: sensor.kettle_power # optional: the tile's own entity when left out
hours: 24To add one, edit a tile card, choose Add feature and pick Chartdeck chart. Its own editor, inside the tile card's editor, has every option below.
style |
What it draws |
|---|---|
sparkline (default) |
The last hours of history as a line, filled below unless fill: false
|
column |
The same history as columns: one per hour for two days or less, one per day beyond |
bar |
The current value between min and max, filling the strip, with the target as a mark |
| Option | Type | Default | Editor |
|---|---|---|---|
style |
sparkline, column, bar
|
sparkline |
Look |
entity |
entity id | the tile's entity | Entity |
attribute |
attribute name | none (the state) | Attribute (instead of the state) |
hours |
number of hours, above 0 and at most 168 | 24 |
Hours of history (sparkline and columns) |
fill |
true / false | true |
Fill below the line (sparkline only) |
aggregate |
auto, mean, sum, min, max, first, last, change
|
auto |
Combine with (columns only) |
min |
number or entity | 0 |
Minimum |
max |
number or entity | 100 |
Maximum |
target |
number or entity | none | Target (bar only) |
unit |
text | the entity's unit | Unit |
decimals |
whole number, 0–20 | as on the card | Decimals |
color |
palette name or any CSS colour | the tile's colour | Colour without bands |
severity |
list of bands | none | Colour bands |
tap_action, hold_action, double_tap_action
|
action |
more-info, none, none
|
Actions |
- The options mean the same as on the card, because the feature runs them through the card's own code:
min,max,targetand band starts can be numbers or entities,unitconverts as on the card (see Options), and decimals follow the entity's display precision. -
Entity: the feature's own
entitywhen set, otherwise the tile's. A feature with its own entity suits a switch's tile showing its plug's power. -
Colour: the colour of the band the value is in when
severityis set, otherwisecolor, otherwise the tile's own colour, which follows the entity's state as the tile's icon does. -
Columns:
aggregate: autoshows how much a meter (state classtotal_increasingortotal) rose in each column, such as energy per hour, and the average for anything else. - Taps open the more-info dialog of the feature's entity, which is handy when it isn't the tile's. Tapping the rest of the tile does what the tile does.
- Unavailable entities draw faded, and a bar has no fill or target. An entity with no history yet draws a faint dashed line.
- The history loads once and then adds new states as they arrive. It stops while the tile isn't on the page.
- Screen readers hear the feature as "Kettle power, last 24 h: 2.1 kW".
Chartdeck chart is offered in the feature list for a tile whose entity has a number to draw: a state that is a number, a unit or a state class, or a number in an attribute such as a thermostat's current temperature, a cover's position or a light's brightness. It is also offered on a switch or plug whose device has a power or energy sensor (power first), and starts on that sensor. Older Home Assistant versions don't tell the feature which device a tile is on, so there it is offered on every switch, light, fan, input boolean and binary sensor tile.
A new feature starts as a sparkline of what it found: the sensor itself, a thermostat's current_temperature, or the plug's power sensor.
In the feature editor: Look and Entity first ("Empty: the tile's entity."), then the attribute, Hours of history with Fill below the line or Combine with; Unit and Decimals; Colour without bands; then Minimum, Maximum and, for the bar, Target (each with Default, Number and Entity, as in the card's Limits section), Colour bands and Actions.
The feature is static: it has no draw-in animation. It reads history only, so it shows at most a week; for longer spans, use a card. It needs a Home Assistant with tile card features (2024.8 or later).
Every card option is described on the Options page; the feature reads the ones in the table above.
Start
Using it
-
Styles
- Bar
- Thin
- Segmented
- Tank
- Ring
- Needle
- Arc
- Line
- Area
- Column
- Combined
- Pie and donut
- Rings
- Pictograph
- Waffle
- Histogram
- Scatter
- Bubble
- Heatmap
- Box plot
- Funnel
- Waterfall
- Treemap
- Sunburst and icicle
- Radar
- Polar area
- Grouped and stacked bars
- Bullet
- Lollipop
- Slope
- Dumbbell
- Range area
- Sparkline
- Streamgraph
- Candlestick
- Violin and raincloud
- Beeswarm
- State timeline
- Climate
- Sankey
- Wind rose
- 24-hour clock
- Trend
- Marimekko
- Chord
- Battery grid
- Spiral
- Strip plot
- Cycle plot
- Duration curve
- Time in each state
- Badge
- Tile feature
- Options
- Visual editor
- Colour bands
Help