Home assistant graph

Home assistant graph DEFAULT

Lovelace Mini Graph Card

A minimalistic and customizable graph card for Home Assistant Lovelace UI.

The card works with entities from within the sensor & binary_sensor domain and displays the sensors current state as well as a line graph representation of the history.

Preview

Install

HACS (recommended)

This card is available in HACS (Home Assistant Community Store).
HACS is a third party community store and is not included in Home Assistant out of the box.

Manual install

  1. Download and copy from the latest release into your directory.

  2. Add the resource reference as decribed below.

CLI install

  1. Move into your directory.

  2. Grab :

  1. Add the resource reference as decribed below.

Add resource reference

If you configure Lovelace via YAML, add a reference to inside your :

resources: - url: /local/mini-graph-card-bundle.js?v=0.10.0type: module

Else, if you prefer the graphical editor, use the menu to add the resource:

  1. Make sure, advanced mode is enabled in your user profile (click on your user name to get there)
  2. Navigate to Configuration -> Lovelace Dashboards -> Resources Tab. Hit orange (+) icon
  3. Enter URL and select type "JavaScript Module".
  4. Restart Home Assistant.

Updating

If you have a version older than v0.0.8 installed, please delete the current files and follow the installation instructions again.

  1. Find your file in or wherever you ended up storing it.

  2. Replace the local file with the latest one attached in the latest release.

  3. Add the new version number to the end of the cards reference url in your like below:

resources: - url: /local/mini-graph-card-bundle.js?v=0.10.0type: module

You may need to empty the browsers cache if you have problems loading the updated card.

Using the card

Options

Card options

NameTypeDefaultSinceDescription
type (required)stringv0.0.1.
entities (required)listv0.2.0One or more sensor entities in a list, see entities object for additional entity options.
iconstringv0.0.1Set a custom icon from any of the available mdi icons.
namestringv0.0.1Set a custom name which is displayed beside the icon.
unitstringv0.0.1Set a custom unit of measurement.
tap_actionaction objectv0.7.0Action on click/tap.
groupbooleanv0.2.0Disable paddings and box-shadow, useful when nesting the card.
hours_to_showintegerv0.0.2Specify how many hours of history the graph should present.
points_per_hournumberv0.2.0Specify amount of data points the graph should display for each hour, (basically the detail/accuracy/smoothing of the graph).
aggregate_funcstringv0.8.0Specify aggregate function used to calculate point/bar in the graph.
group_bystringv0.8.0Specify type of grouping of data, dynamic , or .
update_intervalnumberv0.4.0Specify a custom update interval of the history data (in seconds), instead of on every state change.
cachebooleanv0.9.0Enable/disable local caching of history data.
showlistv0.2.0List of UI elements to display/hide, for available items see available show options.
animatebooleanv0.2.0Add a reveal animation to the graph.
heightnumberv0.0.1Set a custom height of the line graph.
bar_spacingnumberv0.9.0Set the spacing between bars in bar graph.
line_widthnumberv0.0.1Set the thickness of the line.
line_colorstring/listv0.0.1Set a custom color for the graph line, provide a list of colors for multiple graph entries.
color_thresholdslistv0.2.3Set thresholds for dynamic graph colors, see Line color object.
color_thresholds_transitionstringv0.4.3Color threshold transition, or .
decimalsintegerv0.0.9Specify the exact number of decimals to show for states.
hour24booleanv0.2.1Set to to display times in 24-hour format.
font_sizenumberv0.0.3Adjust the font size of the state, as percentage of the original size.
font_size_headernumberv0.3.1Adjust the font size of the header, size in pixels.
align_headerstringv0.2.0Set the alignment of the header, , , or .
align_iconstringv0.2.0Set the alignment of the icon, , or .
align_statestringv0.2.0Set the alignment of the current state, , or .
lower_boundnumber or stringv0.2.3Set a fixed lower bound for the graph Y-axis. String value starting with ~ (e.g. ) specifies soft bound.
upper_boundnumber or stringv0.2.3Set a fixed upper bound for the graph Y-axis. String value starting with ~ (e.g. ) specifies soft bound.
min_bound_rangenumberv0.x.xApplied after everything, makes sure there's a minimum range that the Y-axis will have. Useful for not making small changes look large because of scale.
lower_bound_secondarynumber or stringv0.5.0Set a fixed lower bound for the graph secondary Y-axis. String value starting with ~ (e.g. ) specifies soft bound.
upper_bound_secondarynumber or stringv0.5.0Set a fixed upper bound for the graph secondary Y-axis. String value starting with ~ (e.g. ) specifies soft bound.
min_bound_range_secondarynumberv0.x.xApplied after everything, makes sure there's a minimum range that the secondary Y-axis will have. Useful for not making small changes look large because of scale.
smoothingbooleanv0.8.0Whether to make graph line smooth.
state_mapstate map objectv0.8.0List of entity states to convert (order matters as position becomes a value on the graph).
value_factornumber0v0.9.4Scale value by order of magnitude (e.g. convert Watts to kilo Watts), use negative value to scale down.
logarithmicbooleanv0.10.0Use a Logarithmic scale for the graph

Entities object

Entities may be listed directly (as per in the example below), or defined using properties of the Entity object detailed in the following table (as per in the example below).

NameTypeDefaultDescription
entity (required)stringEntity id of the sensor.
namestringSet a custom display name, defaults to entity's friendly_name.
colorstringSet a custom color, overrides all other color options including thresholds.
unitstringSet a custom unit of measurement, overrides set in base config.
aggregate_funcstringOverride for aggregate function used to calculate point on the graph, , , , , , .
show_statebooleanDisplay the current state.
show_indicatorbooleanDisplay a color indicator next to the state, (only when more than two states are visible).
show_graphbooleanSet to false to completely hide the entity in the graph.
show_linebooleanSet to false to hide the line.
show_fillbooleanSet to false to hide the fill.
show_pointsbooleanSet to false to hide the points.
show_legendbooleanSet to false to turn hide from the legend.
state_adaptive_colorbooleanMake the color of the state adapt to the entity color.
y_axisstringIf 'secondary', displays using the secondary y-axis on the right.
fixed_valuebooleanSet to true to graph the entity's current state as a fixed value instead of graphing its state history.
smoothingbooleanOverride for a flag indicating whether to make graph line smooth.
entities: - sensor.temperature - entity: sensor.pressurename: Pressureshow_state: true - sensor.humidity

Available show options

All properties are optional.

NameDefaultOptionsDescription
name / Display name.
icon / Display icon.
state / Display current state.
graph / / Display option for the graph.
fill / / Display the line graph fill.
points / / Display graph data points.
legend / Display the graph legend (only shown when graph contains multiple entities).
average / Display average information.
extrema / Display max/min information.
labels / / Display Y-axis labels.
labels_secondary / / Display secondary Y-axis labels.
name_adaptive_color / Make the name color adapt with the primary entity color.
icon_adaptive_color / Make the icon color adapt with the primary entity color.

Line color object

See dynamic line color for example usage.

NameTypeDefaultDescription
value (required)numberThe threshold for the color stop.
color (required)stringColor in 6 digit hex format (e.g. ).

Action object options

NameTypeDefaultOptionsDescription
actionstring / / / / Action to perform.
entitystringAny entity idOverride default entity of , when is defined as .
servicestringAny serviceService to call (e.g. ) when is defined as .
service_dataobjectAny service dataService data to include with the service call (e.g. ).
navigation_pathstringAny pathPath to navigate to (e.g. ) when is defined as .
urlstringAny URLURL to open when is defined as .

State map object

NameTypeDefaultDescription
value (required)stringValue to convert.
labelstringsame as valueString to show as label (if the value is not precise).

Aggregate functions

Recorded values are grouped in time buckets which are determined by , configuration. These buckets are converted later to single point/bar on the graph. Aggregate function defines the methods of that conversion.

NameSinceDescription
v0.8.0Average
v0.8.0Minimum - lowest value
v0.8.0Maximum - largest value
v0.9.0
v0.9.0
v0.9.2
v0.9.4Calculates difference between max and min value

Theme variables

The following theme variables can be set in your HA theme to customize the appearance of the card.

NameDefaultDescription
mcg-title-letter-spacingLetter spacing of the card title ( option).
mcg-title-font-weight500Font weight of the card title.

Example usage

Single entity card

Single entity card

- type: custom:mini-graph-cardentities: - sensor.illumination

Alternative style

Alternative style

- type: custom:mini-graph-cardentities: - sensor.illuminationalign_icon: leftalign_state: centershow: fill: false

Multiple entities card

Multiple entities card

- type: custom:mini-graph-cardname: SERVERicon: mdi:serverentities: - entity: sensor.server_totalname: TOTAL - sensor.server_sent - sensor.server_received

Bar chart card

Bar chart card

- type: custom:mini-graph-cardentities: - entity: sensor.energy_consumptionname: ENERGY CONSUMPTIONshow: graph: bar

Show data from the past week

Show data from the past week

Use the option to specify how many hours of history the graph should represent. Use the option to specify the accuracy/detail of the graph.

- type: custom:mini-graph-cardentities: - sensor.living_room_tempname: LIVING ROOMhours_to_show: 168points_per_hour: 0.25

Graph only card

Use the option to show/hide UI elements.

- type: custom:mini-graph-cardentities: - sensor.humidityshow: icon: falsename: falsestate: false

Horizontally stacked cards

You can stack cards horizontally by using one or more .

Horizontally stacked cards

- type: horizontal-stackcards: - type: custom:mini-graph-cardentities: - sensor.humidityline_color: blueline_width: 8font_size: 75 - type: custom:mini-graph-cardentities: - sensor.illuminationline_color: '#e74c3c'line_width: 8font_size: 75 - type: custom:mini-graph-cardentities: - sensor.temperatureline_color: var(--accent-color)line_width: 8font_size: 75

Dynamic line color

Have the graph change line color dynamically.

Dynamic line color

- type: custom:mini-graph-cardentities: - sensor.sensor_temperatureshow: labels: truecolor_thresholds: - value: 20color: "#f39c12" - value: 21color: "#d35400" - value: 21.5color: "#c0392b"

Alternate y-axis

Have one or more series plot on a separate y-axis, which appears on the right side of the graph. This example also shows turning off the line, points and legend.

Alternate y-axis

- type: custom:mini-graph-cardentities: - entity: sensor.verandahname: Verandah - entity: sensor.loungename: Lounge - entity: sensor.kitchenname: Kitchen - color: grayentity: input_number.nighttimename: Nightshow_line: falseshow_points: falseshow_legend: falsey_axis: secondaryshow: labels: truelabels_secondary: true

Grouping by date

mini_energy_daily

You can group values by date, this way you can visualize for example daily energy consumption.

- type: custom:mini-graph-cardentities: - entity: sensor.energy_dailyname: Energy consumptionhours_to_show: 168aggregate_func: maxgroup_by: dateshow: graph: bar

Data aggregation functions

You can decide how values are aggregated for points on graph. Example how to display min, max, avg temperature per day from last week.

mini_temperature_aggregate_daily

- type: custom:mini-graph-cardentities: - entity: sensor.outside_tempaggregate_func: maxname: Maxcolor: #e74c3c - entity: sensor.outside_tempaggregate_func: minname: Min - entity: sensor.outside_tempaggregate_func: avgname: Avgcolor: greenname: Temp outside daily (last week)hours_to_show: 168group_by: date

Non-numeric sensor states

mini_binary_sensor

You can render non-numeric states by providing state_map config. For example this way you can show data coming from binary sensors.

- type: custom:mini-graph-cardentities: - entity: binary_sensor.living_room_motionname: Living room - entity: binary_sensor.corridor_motionname: Corridor - entity: binary_sensor.master_bed_motionname: Master bed.color: green - entity: binary_sensor.bedroom_motionname: Bedroomname: Motion last hourhours_to_show: 1points_per_hour: 60update_interval: 30aggregate_func: maxline_width: 2smoothing: falsestate_map: - value: "off"label: Clear - value: "on"label: Detected

Development

  1. Clone this repository into your folder using git:
  1. Add a reference to the card in your :
resources: - url: /local/mini-graph-card/dist/mini-graph-card-bundle.jstype: module

Instructions

Requires & .

  1. Move into the repo, checkout the dev branch & install dependencies:
$ cd mini-graph-card && git checkout dev && npm install
  1. Make changes to the source code.

  2. Build the source by running:

  1. Refresh the browser to see changes.

    Make sure cache is cleared or disabled.

  2. (Optional) Watch the source and automatically rebuild on save:

The new will be build and ready inside .

If you plan to submit a PR, please base it on the branch.

Getting errors?

Make sure you have in your under .

Make sure you have the latest versions of & .

If you have issues after updating the card, try clearing your browser cache.

If you have issues displaying the card in older browsers, try changing to at the card reference in .

Sours: https://github.com/kalkih/mini-graph-card

ApexCharts card - A highly customizable graph card

ok so… How do I define a =header? If I set header to true it uses the first sensor name and value?
Can I change the colour of the lines?
image

DavidFW1960:

If I set header to true it uses the first sensor name and value?

Yes, for now. Did you want to define a title instead?

DavidFW1960:

Can I change the colour of the lines?

Not yet, but it’s coming, very soon :blush:

Best way for me to track the requests is to open them on Github. You’ll automatically be notified once released in beta and stable. :blush:

Yes define a title… is that an option? Like your traffic sources…

It’s not yet possible but I’ll add it. Would you mind opening the 2 feature requests on GH? I’ll work on this tomorrow. It should be released by the end the day for me tomorrow (CET timezone)

1 Like

yep will do right now
DONE

1 Like

VDRainer (🍻) #8

This is amazing, Thanks alot! :tada:


This is a browser_mod popup.

Waiting for colors support. :slightly_smiling_face:

7 Likes

bschatzow (Bill Schatzow) #9

Nicely done. Can’t wait for the time line boundaries. Should help in troubleshooting my update problems on the OS from 5.2 to 5.10. I should be able to see what is going on when my Pi4 freezes.

alnavasa (A) #10

Installed.
I am missing the ability to change line width,
I’ll keep testing!

dproffer (David Proffer) #11

Here is an example that might help:

You can change the line width. See just above

1 Like

Just for general knowledge:
This:

Is the same as this:

1.1.0 (2021-01-26)

:warning: BREAKING CHANGES

  • Replace with . Takes a time string instead of a number of hours.

Features

  • Replace with . Takes a time string instead of a number of hours. (e7ed408)
  • color: Define your own option for each (#7) (3a15db2), closes #4
  • header: More header options and title support (#8) (2cbd769), closes #5
  • Add config option (357db9a), closes #2

Bug Fixes

  • tooltip: Values where following the selected point (0145ca2)
  • Error was not displayed if duration couldn’t be parsed (2e2212f)
  • Name and units displayed (fe5526b)

Documentation

  • Add examples and fix documentation (c71b76a)
  • Fix typos and broken links (7789b8f)

Chores

  • changelog: Add doc and chores sections (58d7f5f)
  • release: 1.1.0-dev.1 [skip ci] (e15f7b9), closes #2
  • release: 1.1.0-dev.2 [skip ci] (f01afd7), closes #4#5

3 Likes

bschatzow:

Nicely done. Can’t wait for the time line boundaries. Should help in troubleshooting my update problems on the OS from 5.2 to 5.10. I should be able to see what is going on when my Pi4 freezes.

This is released in beta. Feedback welcome :slight_smile: Check the README in the dev branch for updated documentation.

Love this already… Kudos!

1 Like

NdR (Andrea Montanari) #17

Thanks for this incredible work!

I love this card!

1 Like

bschatzow (Bill Schatzow) #18

It woks. Now is there a simple way to load a specific time range? I.E yesterday at 3PM to 5PM. What I see for the current code is a offset from the current time (which is always changing as the time is changing). Not sure how many people need this but there are times I want to see my history at a known time.

For yesterday 3pm to 5pm you can do it this way:

bschatzow (Bill Schatzow) #20

next page →

Sours: https://community.home-assistant.io/t/apexcharts-card-a-highly-customizable-graph-card/272877
  1. Pure protein superfood
  2. Player two csgo
  3. Rope rail brackets
  4. Mind reader shelves
  5. Rechargeable mini saw

How to seamlessly add Grafana graphs to Home Assistant

Published by Oliver on

Home Assistant dashboard are great, but Grafana is even more powerful. So why not combine them and embed your Grafana graphs directly into your Home Assistant dashboard? It is actually pretty simple.

How to push your Home Assistant data into Grafana

To get your data from Home Assistant to Grafana you first need to combine both. I described this in depth in this article. Basically you can tell Home Assistant to also save all its data in a separate InfluxDB database and then read that data from Grafana. Grafana is a great tool to build beautiful looking and very informative graphs from that data and to drill down into any part of it.

While Home Assistant also offers build-in data visualization tools they are not as powerful nor as good looking (without more customization). You can of course add pretty much everything you want via HACS but you can also just use Grafana as one single and powerful tool.

Preparing Grafana for sharing

To simply embed Grafana elements somewhere else (Home Assistant in our case) you need to first disable some security measurements. Usually you can only Grafana data when you are logged in. That is definitely important for bigger networks or public instances but in my case Grafana is only available inside my own network so I do not think I really need access control here.

Grafana settings can be edited in the Grafana configuration, which can be a file or in case of a Docker installation environment variables. On my custom smart home server the software, including Grafana, InfluxDB and Home Assistant) runs in Docker containers managed by docker-compose. I can really recommend this setup as changing settings like this only means adding a couple of lines and restarting one container.

As always you can find all the code in my GitHub repository for my smart home server. Go to the Grafana container (in my case in the file) and add a couple of new environment variables.

This will allow you to access your Grafana dashboards without having to log in and disables a security measure that prevents you from using Grafana in an iframe (basically a website in a website). Then just restart your Grafana container via Now we can include Grafana in Home Assistant dashboards.

How to include single Grafana panels in a Home Assistant dashboard

After the previously explained changes you can now very easily add single panels to your Home Assistant dashboard. Just go to your Grafana panel, click on the title and select share.

In the menu that pops up you can switch to the Embed tab and copy the src URL part from the text box. Before you do that you can also switch of the current time range slider above. That way the timeframe for the Grafana data shown in the diagram will automatically keep updating.

Now you can go back to your Home Assistant dashboard and add a new webpage card to your dashboard.

Enter the URL copied from Grafana and click close. You should now see this diagram in your dashboard! Of course you can repeat the process to add more.

How to add a full Grafana dashboard to Home Assistant

You can not only add single panels from Grafana but you can also include a full Grafana dashboard in Home Assistant. Go to the dashboard in Grafana and click the share icon next to the title.

Disable the lock timerange and copy the link. I personally also added to the URL to get rid of the side menu.

Then go back to Home Assistant and create a new tab in your dashboard. Enable the panel mode to make your Grafana panel use the full space and give it a title. Then add one webpage card and paste the link from above.

a full grafana dashboard in home assistant

Now you have a tab in your dashboard that includes the full Grafana screen including the box at the top that allows you to change timeframes. You can also still switch very quickly back to your other tabs to control your devices. Pretty awesome! The only disadvantage is that it takes a small moment to load the Grafana elements after you open the tab. As it is all within your network it should load really fast though.

Sours: https://thesmarthomejourney.com/2021/05/30/add-grafana-to-home-assistant/

Sensor Card


The Sensor card gives you a quick overview of your sensors state with an optional graph to visualize change over time.

Screenshot of the sensor card Screenshot of the sensor card.

To add the Sensor card to your user interface, click the Lovelace menu (three dots at the top right of the screen) and then Edit Dashboard. Click the “Add Card” button in the bottom right corner and select Sensor from the card picker. All options for this card can be configured via the user interface.

Configuration Variables

Looking for your configuration file?

type stringRequired

entity stringRequired

Entity ID of domain.

icon string (Optional)

name string (Optional)

graph string (Optional)

Type of graph ( or ).

unit string (Optional)

detail integer (Optional, default: 1)

Detail of the graph or ( = one point/hour, = six points/hour).

hours_to_show integer (Optional, default: 24)

Hours to show in graph. Minimum is 1 hour. Big values can result in delayed rendering, especially if the selected entities have a lot of state changes.

limits map (Optional)

Limits of the graph Y-axis.

min float (Optional)

Minimum value of the graph Y-axis.

Default:

if the entity is , otherwise minimum value of sample

max float (Optional)

Maximum value of the graph Y-axis.

Default:

if the entity is , otherwise maximum value of sample

theme string (Optional)

Override the used theme for this card with any loaded theme. For more information about themes, see the frontend documentation.

Example

Alternatively, the card can be configured using YAML:

Sours: https://www.home-assistant.io/lovelace/sensor/

Graph home assistant

These are the most popular Lovelace (Home Assistant dashboard) cards

In my opinion, one of the best things about the Home Assistant dashboard (Lovelace) is the fact that you can add custom cards. While I do not have the capabilities of developing my own cards, a bunch of very useful cards have emerged from the Home Assistant community. Some of these cards have been developed specifically for a single integration, such as the Lovelace Xiaomi Vacuum Map card, while others can be used more broadly.

As with most Home Assistant community add-ons, these cards are available from the Home Assistant Community Store. And as always, I recommend you install them using the store. That way, you will be able to update any of the cards from the Home Assistant dashboard.

Lovelace Mini Graph Card

The Lovelace Mini Graph Card is one of my absolute favourite custom Lovelace cards. And I’m not alone in that thinking. With over 1000 stars on GitHub, the developer has seemingly struck gold in the Home Assistant community. The Lovelace Mini Graph Card is a big improvement over the default History Graph Card.

Setting up the Lovelace Mini Graph Card is not the easiest of tasks, as there are a ton of customization options available. But once you get going, you will soon find yourself adding this card wherever possible. Among many other things, I use this card to monitor the following:

This card can also be used to monitor the temperature and humidity of rooms over time, display your power consumption over time, and tell you in which room motion has been detected. Any sensor and binary sensor can be displayed using this card.

This Lovelace card gets a definite recommendation from me. Using it, you can display sensor information in an attractive and useful way.

Mini Media Player

The second most popular custom Lovelace card is another one I use on many of my views, mainly to control my multiple Google Nest smart speakers. It is, of course, the popular Mini Media Player with currently over 725 stars on GitHub. Incidentally, the same person who is responsible for the Lovelace Mini Graph Card developed this card. Developer Karl Kihlström seems to know what Home Assistant dashboards need.

If you use either this card or the Lovelace Mini Graph Card and want to support the further development, you can sponsor the developer on PayPal. More information about their further projects, such as the community-sourced lyrics app Singlyricly, can be found on their personal website.

Lovelace Button card

This card is, as with the previously mentioned cards, a more customizable alternative to what is included with Home Assistant out of the box. The Lovelace Button card works with any toggleable entity.

You can select from six available actions on tap, hold, or double click: none, toggle, more-info, navigate, URL and call-service. Furthermore, you can create your own layouts, customize the aspect ratio, use icons of your liking, and even use JavaScript templates in some fields.

In contrast to the top two cards, I have never used this one extensively. I have had a play around with it, but ,so far, it isn’t used on any of my non-testing views.

Sours: https://home-assistant-guide.com/2020/10/14/these-are-the-most-popular-lovelace-home-assistant-dashboard-cards/
Visualize your Data! Home Assistant Energy Portal and Statistics Graph Cards

Statistics Graph Card


The Statistics Graph card allows you to display a graph of statistics data for each of the entities listed.

Statistics are gathered every hour for sensors that support it. It will either keep the , and of a sensors value for a specific hour, or the for a metered entity.

If your sensor doesn’t work with statistics, check this.

Screenshot of the statistics graph card for power entities Screenshot of the Statistics Graph card with none metered entities and `chart_type` `line`.

Screenshot of the statistics graph card for energy entities Screenshot of the Statistics Graph card with a metered entity and `chart_type` `bar`.

To add the Statistics Graph card to your user interface, click the Lovelace menu (three dots at the top right of the screen) and then Edit Dashboard. Click the “Add Card” button in the bottom right corner and select Statistics Graph from the card picker. All options for this card can be configured via the user interface.

Configuration Variables

Looking for your configuration file?

type stringRequired

entities listRequired

A list of entity IDs or objects, see below.

days_to_show integer (Optional, default: 30)

Days to show in graph. Minimum is 1 day.

chart_type string (Optional)

If the chart should be rendered as a or a chart.

stat_types list (Optional)

The stat types to render. , , ,

title string (Optional)

Options For Entities

If you define entities as objects instead of strings, you can add more customization and configuration:

Example

Alternatively, the card can be configured using YAML:

Sours: https://www.home-assistant.io/lovelace/statistics-graph/

Similar news:

History Graph Card


The History Graph card allows you to display a graph for each of the entities listed.

Screenshot of the history graph card for entities without a unit_of_measurement Screenshot of the History Graph card, when the sensor has no `unit_of_measurement` defined.

Screenshot of the history graph card for entities with a unit_of_measurement Screenshot of the History Graph card, when the sensor has a `unit_of_measurement` defined.

To add the History Graph card to your user interface, click the Lovelace menu (three dots at the top right of the screen) and then Edit Dashboard. Click the “Add Card” button in the bottom right corner and select History Graph from the card picker. All options for this card can be configured via the user interface.

Configuration Variables

Looking for your configuration file?

type stringRequired

entities listRequired

A list of entity IDs or objects, see below.

hours_to_show integer (Optional, default: 24)

Hours to show in graph. Minimum is 1 hour. Big values can result in delayed rendering, especially if the selected entities have a lot of state changes.

refresh_interval integer (Optional, default: 0)

Refresh interval in seconds.

title string (Optional)

Options For Entities

If you define entities as objects instead of strings, you can add more customization and configuration:

Example

Alternatively, the card can be configured using YAML:

Sours: https://www.home-assistant.io/lovelace/history-graph/


392 393 394 395 396