grafana-util docs

dashboard diff

What this page covers

Compare local dashboard files against live Grafana dashboards.

When to open this page

  • Use this when you want to see what would change before importing or publishing a dashboard bundle.

Who this page is for

Best for SREs, Grafana operators, and responders working with dashboard inventory, migration, inspection, or screenshots.

Purpose

Compare local dashboard files against live Grafana dashboards.

When to use

Use this when you want to see what would change before importing or publishing a dashboard bundle.

Key flags

  • --input-dir: compare this export directory against Grafana.
  • --input-format: choose raw or provisioning.
  • --import-folder-uid: override the destination folder UID for the comparison.
  • --context-lines: unified diff context.
  • --output-format: choose text or json.

Examples

# Purpose: Compare local dashboard files against live Grafana dashboards.
grafana-util dashboard diff --url http://localhost:3000 --basic-user admin --basic-password admin --input-dir ./dashboards/raw
# Purpose: Compare local dashboard files against live Grafana dashboards.
grafana-util dashboard diff --url http://localhost:3000 --basic-user admin --basic-password admin --org-id 2 --input-dir ./dashboards/raw --output-format json

CLI schema lookup: