Windows Performance Recorder

Also known as: WPR

On this page 7

Windows Performance Recorder (WPR) is the Microsoft tool that records Event Tracing for Windows (ETW) data from the kernel and applications into a trace file, so that performance problems can be analyzed precisely after the fact. In Windows performance work, it is the capture half of a two-tool workflow: WPR records, and Windows Performance Analyzer opens and visualizes the resulting .etl file.

WPR ships with current versions of Windows as wpr.exe and is also part of the Windows Performance Toolkit in the Windows Assessment and Deployment Kit, which adds the graphical recorder. Unlike live monitors such as Task Manager or Resource Monitor, it keeps a timestamped record of every sampled event, which makes it suitable for diagnosing slow boots, stutters, hangs and high resource usage that are hard to catch in real time.

How Windows Performance Recorder captures ETW events

WPR works as an ETW controller: it starts tracing sessions, enables the selected providers, sets buffer sizes and later merges the collected events into one file. The providers themselves, such as the NT Kernel Logger and application providers, generate the events; WPR only decides what is collected and how.

Collection is defined by profiles, which are XML descriptions of providers, keywords, stack-walk settings and buffers. Built-in profiles cover common scenarios, and custom .wprp profiles can add application-specific providers. A key option is stack walking, which records call stacks with samples so that time can be attributed to individual functions.

The table below lists the main recording modes and how they differ.

ModeHow events are keptTypical use
Memory modeCircular in-memory buffersCatching a rare stutter after it happens
File modeWritten continuously to diskLong, complete traces of a scenario
Boot traceStarted before user sign-inAnalyzing slow startup and logon
Shutdown traceCaptures the shutdown sequenceDiagnosing slow shutdown or restart
Event-triggered stopEnds on a defined eventProblems that are hard to reproduce
Recording modes in WPR

Built-in WPR profiles and what they collect

Choosing the right profile determines whether the trace contains the answer. A narrow profile keeps files small and overhead low, while a broad profile risks gigabytes of data and noticeable slowdown. The following table summarizes frequently used built-in profiles.

ProfileMain data collectedQuestion it answers
GeneralProfileCPU, disk, file I/O, basic memoryWhat is the system doing overall
CPUSampled CPU usage with stacksWhich code consumes processor time
DiskIO and FileIOStorage requests and file operationsWhy the disk is busy or slow
Heap and VirtualAllocationMemory allocations with stacksWhere memory grows or leaks
NetworkTCP/IP and networking eventsWhere network delays occur
GPU and VideoGraphics scheduling and framesWhy frames drop or stutter
Common built-in recording profiles

Profiles can be combined in one session, for example CPU with DiskIO. Each profile also has a detail level, typically Light or Verbose, which controls how many events and stacks are kept. Verbose tracing is precise but can generate several hundred megabytes per minute on a busy machine.

WPR compared with other Windows performance tools

WPR is the deep forensic option among Windows performance tools: it is slower to use but answers questions that live monitors cannot. Its neighbors serve different purposes, as the comparison below shows.

ToolMain strengthMain limitation
Windows Performance RecorderDetailed ETW traces with stacksNeeds analysis in a separate tool
Windows Performance AnalyzerGraphs and tables over tracesCannot record data itself
Performance MonitorLong-term counters and alertsNo call stacks or per-event detail
Resource MonitorLive per-process resource viewNo history beyond the window
Process ExplorerDetailed live process inspectionSnapshot view, not a recording
xperfOlder command-line ETW controllerSuperseded by WPR for most tasks
WPR and related tools

In practice, Performance Monitor shows that a problem exists over hours or days, while WPR shows why it happens during a specific minute.

Using WPR from the command line

The command-line tool wpr.exe is the most common way to record, because it works on any Windows installation without extra software and runs from an elevated command prompt. A typical session follows a short sequence.

  1. Start recording with wpr -start GeneralProfile -start CPU.
  2. Reproduce the problem, ideally for 30 to 120 seconds.
  3. Stop and save with wpr -stop C:\traces\issue.etl.
  4. Cancel an unwanted session with wpr -cancel.
  5. List available profiles with wpr -profiles.

For boot analysis, wpr -boottrace -addboot GeneralProfile arms tracing for the next restart. The filemode switch writes events directly to disk instead of memory buffers, which suits long captures. After saving, WPR also gathers symbol and image information so that Windows Performance Analyzer can resolve function names.

Limitations and common mistakes with WPR

WPR is powerful but easy to misuse, and a poorly scoped trace often contains too much data or the wrong data. The table below lists frequent mistakes and how to avoid them.

MistakeConsequenceBetter practice
Recording for many minutesHuge files and lost buffersKeep the capture short and focused
Using every profile at onceHigh overhead distorts resultsStart with GeneralProfile and narrow down
Running without elevationKernel providers fail to startUse an administrator prompt
Stopping before the problem endsKey events are missingStop only after the symptom finishes
Sharing traces without reviewExposure of paths and process namesTreat .etl files as sensitive data
Frequent WPR mistakes

A trace also has an observer effect: verbose stack walking adds CPU load and disk writes that can alter timing-sensitive problems. Finally, an .etl file may contain user names, file paths, URLs and window titles, so it should be handled under the same privacy rules as other diagnostic data.

Stripped to the essentials

Windows Performance Recorder is a flight data recorder for your PC. While it runs, it writes down what the processor, disk, memory and programs are doing, many times per second.

Afterward, an expert opens the recording in a companion tool and replays it. This makes it possible to find the exact cause of a slowdown, even if the problem lasted only a few seconds. The recorder itself shows no charts. Its job is to capture the evidence.

Where it is applied

An IT support team receives complaints that laptops in one department take more than three minutes to reach a usable desktop after sign-in. Task Manager shows nothing unusual once the desktop appears, so the team cannot see the cause live.

A technician runs wpr -boottrace -addboot GeneralProfile on one affected laptop, restarts it, signs in and saves the trace. In Windows Performance Analyzer, the boot timeline shows a logon script waiting about 90 seconds for an unreachable network share, while disk activity is low. After the script is corrected through Group Policy, sign-in time falls to under 40 seconds on all affected machines, and the team keeps the trace as evidence for the change record.