- Validating Prometheus configuration files (for example,
prometheus.yml) and rule files. - Validating metrics input formatting so Prometheus can scrape them.
- Running ad hoc queries against a Prometheus server.
- Debugging and profiling a Prometheus server.
- Running unit tests for recording and alerting rules.

check config, which validates your Prometheus configuration file for syntax and unsupported fields before you apply it.
Example: validate a local Prometheus configuration file:
scrape_configs snippet with the correct field name metrics_path. Note the plural form (metrics_path)—this is the correct property.
metric_path (singular) instead of metrics_path—promtool will detect it and point to the offending line and field:
promtool check config on a file containing that typo produces an error similar to:
Use
promtool check config before reloading or restarting Prometheus to avoid downtime caused by invalid configuration changes.