How to Monitor Windows Service and Process Status (Running/Stopped) in Grafana

Monitoring critical Windows services and processes is important to ensure your applications and infrastructure remain healthy. In this blog, I’ll show how to monitor Windows service status (Running/Stopped) using Windows Exporter, Prometheus, and Grafana.

This setup allows you to quickly identify stopped services and visualize their status in a Grafana dashboard.

Prerequisites

Before starting, make sure you have:

  • Windows Exporter installed on the Windows server
  • Prometheus configured to scrape Windows Exporter metrics
  • Grafana connected to Prometheus as a data source

Step 1: Verify Windows Service Metrics

Windows Exporter exposes service information through the metric:


You can verify the metric in Prometheus:
windows_service_state

The metric returns service details along with labels such as:
• name
• state
• instance
• job

Step 2: Create a Table Panel in Grafana

  1. Open Grafana.
  2. Create a new dashboard.
  3. Add a new panel.
  4. Select Table visualization.
  5. Choose Prometheus as the data source.

Step 3: Add the PromQL Query

Use the following query to display selected Windows services:

windows_service_state(
name=~“.*grafana.*|prometheus|.*OpenOpcUaCoreServer.*|.*postgresql.*|.*timescaledb.*|.*pgagent.*|.*windows_exporter.*|.*promtail.*”,
instance=“$instance”
)

You can modify the service names according to your environment.

Step 4: Filter Unwanted Results

The metric returns multiple states for each service.

Add the following transformation:



This makes the table cleaner and easier to read.

Step 7: Configure Value Mappings

To improve readability, configure value mappings for the State column.

Final Result

Your table will display:

The color-coded status immediately highlights any stopped service.
Benefits of This Approach
• Monitor critical Windows services in real time
• Quickly identify stopped services
• Centralized visibility in Grafana
• Easy to customize for any Windows application
• Can be extended with Grafana alerts for automatic notifications

Conclusion

Using Windows Exporter, Prometheus, and Grafana, you can build a simple but effective dashboard to monitor Windows service status. By combining PromQL queries, transformations, and value mappings, Grafana can display a clean service health table that helps administrators quickly identify issues before they impact users.

If you’re already using Grafana for infrastructure monitoring, this is a great addition to your Windows monitoring dashboards.