Tools / Event IDs / Event ID 4801

Event ID 4801: workstation unlocked

What Event ID 4801 (workstation unlocked) means, the fields to check, what is normal and what is suspicious, with PowerShell and KQL queries to find it.

Log: Security · Severity: Informational · Updated 2026-11-03

Event ID 4801 records the workstation being unlocked, the counterpart of 4800. Together they show when a person was at the keyboard.

The fields that matter

FieldWhat it tells you
Subject > Account NameThe user who unlocked.
Session IDThe session.

What is normal

Unlocks during working hours by the usual user.

When Event ID 4801 is suspicious

Common false positive: Normal daily use.

Find Event ID 4801 with PowerShell

Get-WinEvent -FilterHashtable @{LogName='Security'; Id=4801; StartTime=(Get-Date).AddDays(-7)} -MaxEvents 50 |
  ForEach-Object {
    $d = [ordered]@{ Time = $_.TimeCreated; Computer = $_.MachineName }
    ([xml]$_.ToXml()).Event.EventData.Data | ForEach-Object { $d[$_.Name] = $_.'#text' }
    [pscustomobject]$d
  } | Format-List

Microsoft Sentinel (KQL)

SecurityEvent
| where TimeGenerated > ago(7d) and EventID == 4801
| project TimeGenerated, Computer, Account, Activity, EventData
| order by TimeGenerated desc

Related events

FAQ

Does unlocking log a 4624?

Yes, a 4624 with logon type 7 is also written for the unlock.