Skip to content

timmo001/ha-dashboard-maintenance

Repository files navigation

Dashboard Maintenance

Custom Lovelace dashboard and view strategy for Home Assistant maintenance dashboards.

What it adds

  • custom:maintenance dashboard strategy for full dashboards
  • custom:maintenance view strategy for single Lovelace views
  • custom:dm-maintenance-summary-card for linking to maintenance dashboards
  • a strategy editor with a battery attention threshold slider

The generated dashboard focuses on battery-powered devices with numeric battery sensors, orders the devices that need attention first, and opens the device page when you click a tile.

Features

Summary view

Shows a condensed snapshot of every enabled module in one place, with the most critical items listed first.

  • Displays up to 12 items per category from each enabled module.
  • Each category links to its full view when clicked.
  • Items are sorted by urgency: batteries by attention status then level, repairs by severity, updates by install status.
  • Sections only appear when their module is enabled.
  • Shows an empty-state message when no maintenance issues are found.

Maintenance summary card

Use custom:dm-maintenance-summary-card on any dashboard (for example Home Overview) to show a single maintenance count tile that links to your maintenance dashboard.

  • Default metric is batteries needing attention.
  • Metric can be switched to repairs, updates, availability, or stale.
  • Navigation is configurable through tap_action / hold_action (or navigation_path).
  • Summary thresholds and safe-list settings are read from the detected custom:maintenance dashboard strategy.
  • If no maintenance dashboard strategy is found, the card shows an error state.
  • Includes a visual card editor in the Lovelace card editor.

Batteries view

Shows devices with numeric battery sensors, sorted so low-battery devices appear first. Devices can be browsed by area using per-area subviews.

  • Devices below battery_attention_threshold (default 30 %) are highlighted in an attention section at the top.
  • Remaining devices are grouped by floor and area, with unassigned devices in an "Other Devices" section.
  • Per-area subviews let you browse batteries for a single room; an "All Batteries" subview shows every device.
  • When a device has multiple battery sensors the most relevant one is selected automatically.
  • Toggle show_attention_batteries_in_areas to include or exclude attention-level batteries from area sections.

Repairs view

Shows all open Home Assistant repair issues.

  • Issues are split into three sections by severity: Critical, Error, and Warning.
  • Within each section issues are sorted by creation date, newest first.
  • Only active, non-ignored issues are shown.
  • Shows an empty-state message when there are no open repair issues.

Updates view

Shows all pending software and firmware updates.

  • Updates are grouped into four sections: In Progress, Available & Installable, Skipped Versions, and Other (not installable).
  • Each tile shows the friendly name, current version, and latest available version.
  • The Summary view shows only in-progress, skipped, and installable updates.
  • Shows an empty-state message when everything is up to date.

Availability view

Shows entities that are currently unavailable, grouped by area with per-area subviews.

  • Unavailable entities are grouped by device; entities not belonging to any device are listed separately.
  • Per-area subviews let you focus on a single room.
  • Device IDs added to availability_safe_list_device_ids are excluded from tracking. This is intended for devices you know can go offline and/or do not want to track.
  • Shows an empty-state message when all entities are reachable.

Stale view

Shows entities whose state has not been updated within a configurable time window, grouped by area with per-area subviews.

  • Entities are considered stale after stale_threshold_hours hours without an update (default 6 h, range 1–72 h).
  • Monitored domains include sensors, binary sensors, lights, switches, covers, climate, locks, and more.
  • Entities are sorted by staleness, longest first, then alphabetically.
  • Per-area subviews let you browse stale entities for a single room; an "All Stale" subview shows everything.
  • Unavailable entities are excluded because they are unreachable rather than stale.

Install with HACS

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

  1. Open the button above to add this repository in HACS.

  2. If you add it manually, open HACS, go to the top-right menu, choose Custom repositories, add https://github.com/timmo001/ha-dashboard-maintenance, and select Dashboard.

  3. Install the repository from HACS.

  4. Open Settings -> Dashboards -> three dots menu -> Resources.

  5. Add this Lovelace resource:

    • URL: /hacsfiles/ha-dashboard-maintenance/ha-dashboard-maintenance.js
    • Type: module
  6. Reload Lovelace resources or refresh Home Assistant.

Local development setup

The local publish flow copies the built bundle into /config/www/community/ha-dashboard-maintenance/ over SSH with rsync, so your development machine needs ssh and rsync, and your Home Assistant instance needs SSH access set up first.

If you run Home Assistant OS or Supervised, you can use the SSH app:

Open your Home Assistant instance and show the dashboard of an add-on.

  1. Install the SSH app, refer to its setup instructions, and make sure you can log in over SSH before running this script.

  2. Copy .env.example to .env.

  3. Set PUBLISH_TARGET to your Home Assistant SSH target, for example root@homeassistant.local or another SSH user/host that can write to /config/www.

  4. Optionally set PUBLISH_PORT if your SSH service is not on port 22.

  5. Run pnpm publish-to-local.

  6. Open Settings -> Dashboards -> three dots menu -> Resources.

  7. Add this Lovelace resource:

    • URL: /local/community/ha-dashboard-maintenance/ha-dashboard-maintenance.js
    • Type: module
  8. Reload Lovelace resources or refresh Home Assistant.

Strategy usage checklist

  • Register the resource before trying to use custom:maintenance.
  • Use the HACS /hacsfiles/... URL for installed releases.
  • Use the /local/... URL for the default local publish flow.
  • Set the resource type to module.

Use as a full dashboard

YAML example:

strategy:
  type: custom:maintenance
  battery_attention_threshold: 30

Storage dashboard flow:

  1. Create an empty dashboard from /config/lovelace/dashboards.
  2. Open raw configuration.
  3. Replace the config with the strategy example above.
  4. Save the dashboard.

Use as a view in an existing dashboard

views:
  - strategy:
      type: custom:maintenance
      title: Maintenance
      path: maintenance
      icon: mdi:battery-heart-variant
      battery_attention_threshold: 30

Use the maintenance summary card

type: custom:dm-maintenance-summary-card
summary: batteries
tap_action:
  action: navigate
  navigation_path: /maintenance/summary
hold_action:
  action: none

Summary card options

Key Type Default Description
summary "batteries" | "repairs" | "updates" | "availability" | "stale" "batteries" Which summary count to display.
tap_action action config auto-detected maintenance summary path Frontend-style tap action. If unset, the card auto-detects a maintenance dashboard summary path.
hold_action action config none Optional frontend-style hold action.
navigation_path string detected summary path Shortcut path for navigation (used when tap_action is not set).
title string Maintenance Optional primary label override.
icon string mdi:home-heart Optional icon override.

Configuration

All options are optional. Omitting a key uses the default shown below.

Common options (dashboard and view strategy)

Key Type Default Description
batteries_enabled boolean true Enable or disable the batteries module.
battery_attention_threshold number 30 Battery percentage (0 – 100) below which a device is flagged as needing attention.
show_attention_batteries_in_areas boolean true Show attention-flagged batteries inside per-area sections.
repairs_enabled boolean true Enable or disable the repairs module.
updates_enabled boolean true Enable or disable the updates module.
availability_enabled boolean true Enable or disable the availability module.
availability_safe_list_device_ids string[] [] Device IDs to exclude from availability checks.
stale_enabled boolean true Enable or disable the stale-data module.
stale_threshold_hours number 6 Hours (1 – 72) after which an entity is considered stale.

View-only options

These options are only used when the strategy is placed on a single view.

Key Type Description
view "summary" | "batteries" | "repairs" | "updates" | "availability" | "stale" Which view to render.
title string Title shown in the view heading.
path string URL path for the view.
icon string Icon shown in the navigation.
subview boolean Mark this view as a subview (hides it from the sidebar).
area_id string Restrict the view to a single Home Assistant area.
heading_navigation_path string Navigation path displayed in the view heading.

Full example

strategy:
  type: custom:maintenance
  batteries_enabled: true
  battery_attention_threshold: 20
  show_attention_batteries_in_areas: false
  repairs_enabled: true
  updates_enabled: true
  availability_enabled: true
  availability_safe_list_device_ids:
    - abc123def456
  stale_enabled: true
  stale_threshold_hours: 48

Requirements

  • Home Assistant 2026.5 or later (required for the built-in shortcut card used in the availability and integrations views).

Current limitations

  • It does not add a new built-in or system dashboard.
  • It does not appear in the new dashboard template picker, because that picker is currently limited to built-in strategies.
  • It does not modify the Home overview, quick search, or other built-in system dashboard navigation.
  • It only includes devices with numeric battery percentage sensors. Binary low-battery entities are intentionally skipped.
  • The strategy will not load until the Lovelace resource is registered.

Development

pnpm install
pnpm run build
node --check dist/ha-dashboard-maintenance.js

Git commits also run pnpm run lint through a pre-commit hook, which rebuilds the bundle and checks the generated JavaScript syntax.

Release layout

  • HACS release asset: ha-dashboard-maintenance.js
  • Local build output: dist/ha-dashboard-maintenance.js
  • Local publish target: /config/www/community/ha-dashboard-maintenance/ha-dashboard-maintenance.js
  • Recommended local dev resource URL: /local/community/ha-dashboard-maintenance/ha-dashboard-maintenance.js

About

A maintenance dashboard for Home Assistant

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors