Set up Prometheus, windows_exporter, and Grafana to monitor Windows servers with guidance from our Windows Support team

Windows Server Monitoring with Prometheus and Grafana

Windows servers run critical applications and databases, so you must track performance and availability continuously. Many commercial tools add cost and restrict flexibility.

You can instead use Prometheus, windows_exporter (WMI Exporter), and Grafana. This stack collects Windows metrics, stores them efficiently, and displays them through structured dashboards.

Windows Server Monitoring with Prometheus and Grafana

Why Use Prometheus windows_exporter and Grafana

First, the stack is open source. You avoid licensing fees and vendor restrictions.


Next, windows_exporter gathers system-level metrics through Windows Management Instrumentation. As a result, you get visibility into CPU, memory, disks, services, and networking.

In addition, Grafana presents metrics in structured dashboards. You can build custom views and apply filters as needed.

Finally, Prometheus supports rule-based alerting. Consequently, you can detect issues early and respond before users are affected.

Start Monitoring Smarter Today

Chat animation


Step 1 Install windows_exporter on Windows Servers

Download the Installer

Go to the official release page:

https://github.com/prometheus-community/windows_exporter/releases

Download the latest stable MSI file for your architecture (for example, windows_exporter-<version>-amd64.msi).

Run the Installer

Execute the MSI file on each Windows server.

During installation, select the required collectors. For most systems, enable:

  • CPU
  • Memory
  • OS
  • Service
  • Logical Disk
  • Physical Disk
  • Net
  • System

After installation, the service listens on port 9182 by default.

To confirm it works, open a browser on the server:

http://localhost:9182/metrics

If the exporter runs correctly, you will see plaintext metrics such as:
# HELP windows_cpu_time_total ...

Automate Installation with PowerShell

When managing multiple servers, automate deployment. Use the following script:

# List your Windows servers here
$servers = @("Server1", "Server2", "Server3")
# URL for the latest WMI Exporter MSI
$msiUrl = "https://github.com/prometheus-community/windows_exporter/releases/download/v0.18.1/windows_exporter-0.18.1-amd64.msi"
# Local path to download MSI temporarily
$localMsiPath = "$env:TEMP\windows_exporter.msi"
# Download MSI once locally
Invoke-WebRequest -Uri $msiUrl -OutFile $localMsiPath
foreach ($server in $servers) {
Write-Host "Installing WMI Exporter on $server..."
# Copy MSI to remote server Temp folder
Copy-Item -Path $localMsiPath -Destination "\\$server\C$\Temp\windows_exporter.msi" -Force
# Run MSI installer silently with recommended collectors
$installCmd = "msiexec /i C:\Temp\windows_exporter.msi /quiet ENABLED_COLLECTORS=cpu,cs,logical_disk,net,os,system,memory,service /norestart"
Invoke-Command -ComputerName $server -ScriptBlock {
param($cmd)
Invoke-Expression $cmd
} -ArgumentList $installCmd
Write-Host "Installation triggered on $server"
}

Ensure you have administrative privileges and PowerShell remoting enabled.

Step 2 Configure Prometheus

Edit prometheus.yml

Open the configuration file on your Prometheus server.

Add a new scrape job:

scrape_configs:
- job_name: 'windows_servers'
static_configs:
- targets: ['<windows-server-ip>:9182', '<another-windows-server-ip>:9182']

Replace the placeholders with actual IP addresses or hostnames.

Reload Prometheus

Restart Prometheus or reload configuration from:

http://<prometheus-ip>:9090/-/reload
Verify Targets

Open the Prometheus UI.

Navigate to Status and then to Targets.

If configuration works, your Windows servers will show UP.

If not, verify:

  • Firewall rules
  • Network connectivity
  • windows_exporter service status

Step 3 Install and Configure Grafana

Install Grafana

Download Grafana from:

https://grafana.com/grafana/download

Install it on your preferred OS or use Docker.

Access Grafana:

http://<grafana-ip>:3000

Default login: admin/admin

Add Prometheus as Data Source
  1. Go to Configuration then to Data Sources
  2. Select Prometheus
  3. Enter:
http://<prometheus-ip>:9090
  1. Click Save & Test
Import Windows Dashboards

To avoid building dashboards from scratch:

  1. Navigate to Create and then to Import
  2. Use Dashboard ID 14694 or 10467
  3. Select your Prometheus data source

After import, Grafana will display CPU, memory, disk, and service metrics automatically.

Practical Monitoring Examples

High CPU Usage

Backup jobs or scans often increase CPU load.

Track:

windows_cpu_time_total

Create alerts when average CPU usage exceeds 85% for more than five minutes. Then adjust workloads accordingly.

Low Disk Space

Monitor:

windows_logical_disk_free_bytes

Set alerts when free space drops below 10%. Also, review usage trends in Grafana to plan capacity upgrades.

Windows Service Monitoring

Critical services must remain active.

Use:

windows_service_status

Create alerts for unexpected service stops. Display service state in a dedicated Grafana panel for quick review.

Operational and Security Recommendations

Restrict access to port 9182. Only allow Prometheus server IPs.

Add labels such as:

env="prod"
env="dev"

This simplifies filtering and alert rules.

Enable authentication and HTTPS in Grafana.

Keep Prometheus and windows_exporter updated.

Finally, integrate Alertmanager with email or collaboration tools to route alerts without delay.

[Need assistance with a different issue? Our team is available 24/7.]

Conclusion 

Prometheus, windows_exporter, and Grafana together deliver structured monitoring, efficient metric storage, and precise alerting without added licensing costs.

Deploy the stack across your Windows environment and configure targeted alerts to maintain performance and availability with confidence.