How to Clear, Archive, and Manage Windows Event Viewer Logs
Published 2026-10-16 · Marion Remote Fix
Your Windows Event Viewer logs are consuming disk space, the Event Log service is using noticeable CPU or disk resources, you need to clear old logs before troubleshooting a new problem, or you want to archive logs before wiping them. Event logs grow continuously and Windows does not clean them up automatically by default. Here is how to clear logs safely, set size limits, archive important events, and automate log maintenance.
Understand what you are deleting before clearing logs
Before clearing any logs, know what they contain and whether you might need them:
- Application log: records from installed programs — crashes, errors, and status messages. Safe to clear regularly for troubleshooting purposes, but if you are investigating an application problem, check this log first
- System log: records from Windows services, drivers, and hardware — blue screen details, driver failures, service crashes. The most valuable log for diagnosing recurring system problems. Consider archiving before clearing
- Security log: records login attempts, permission changes, and audit events. Important for security investigations. In business environments, regulations may require keeping these logs for a specific period — check with your IT department before clearing
- Setup log: records Windows Update and installation events. Safe to clear after confirming your system is stable
- Clearing a log deletes all events in it permanently. If you might need the events later, archive the log first (see the archiving section below)
Clear logs through Event Viewer
The simplest way to clear individual logs:
- Open Event Viewer (right-click Start → Event Viewer, or press Win+R → type
eventvwr.msc) - In the left panel, expand Windows Logs
- Right-click the log you want to clear (Application, System, Security, or Setup)
- Click Clear Log. Event Viewer asks if you want to Save and Clear or Clear. Choose Save and Clear if you want to keep a backup, or Clear to delete the events immediately
- If you chose Save and Clear, pick a location and filename. The log is saved as an .evtx file that can be reopened in Event Viewer later
- After clearing, the log starts fresh. New events appear as they occur. An Information event is automatically added noting that the log was cleared and who cleared it
Clear all logs at once with PowerShell
If you want to clear all event logs at once rather than one by one:
- Open PowerShell as administrator
- To clear all Windows logs:
Get-EventLog -List | ForEach-Object { Clear-EventLog -LogName $_.Log } - To clear only the main logs:
Clear-EventLog -LogName Application, System, Security, Setup - To clear the newer-style logs (Applications and Services Logs) as well:
wevtutil el | ForEach-Object { wevtutil cl $_ }. This clears every log on the system — use with caution - You can also clear a specific log:
wevtutil cl Systemclears just the System log. Replace System with any log name shown bywevtutil el
Set log size limits
By default, Windows event logs grow to a maximum size and then overwrite the oldest events. You can adjust these limits:
- In Event Viewer, right-click a log → Properties
- The Maximum log size field shows the current limit in KB. Default values vary: Application and System are typically 20 MB (20480 KB), Security may be 128 MB or more
- Adjust the size based on your needs:
- For most home computers, 20-50 MB per log is sufficient. This stores weeks to months of events
- For servers or computers where logs matter for troubleshooting, 100-200 MB per log gives more history
- For computers with limited disk space, 5-10 MB per log keeps only recent events
- Under When maximum event log size is reached, choose the behavior:
- Overwrite events as needed (default) — the oldest events are deleted automatically when the log fills up. Good for most situations
- Archive the log when full, do not overwrite events — creates an archived copy and starts a fresh log. Creates .evtx files in the log directory that accumulate over time
- Do not overwrite events — stops logging when full. Only use this if regulations require you to keep every event and you have a separate process to manage archives
- Click OK to apply the new settings
Set log limits with PowerShell
For automation or managing multiple computers:
- View current log settings:
wevtutil gl Systemshows the System log's maximum size and retention policy - Set the maximum size (in bytes):
wevtutil sl System /ms:52428800sets the System log to 50 MB (52428800 bytes) - Set the retention policy:
wevtutil sl System /rt:true /ab:trueenables auto-backup when full. Use/rt:falsefor overwrite mode - Apply the same settings to all main logs in one script: run
wevtutil sl Application /ms:52428800,wevtutil sl System /ms:52428800, andwevtutil sl Security /ms:52428800
Archive logs before clearing
To keep a copy of your logs for future reference or compliance:
- Through Event Viewer: right-click the log → Save All Events As → choose a location and save as .evtx format. This creates a complete copy of the log that can be opened on any Windows computer
- Through PowerShell:
wevtutil epl System C:\LogArchive\System-2026-11-07.evtxexports the System log to the specified file. Replace the path and date as needed - Save as CSV for spreadsheet analysis: in Event Viewer, right-click the log → Save All Events As → change the file type to CSV. CSV files can be opened in Excel for filtering and analysis but lose some formatting compared to .evtx
- To reopen an archived .evtx file: in Event Viewer, right-click Saved Logs → Open Saved Log → browse to the .evtx file. The archived events appear in Event Viewer just like live logs, and you can filter and search them normally
Automate log cleanup with Task Scheduler
Set up automatic log clearing on a schedule:
- Open Task Scheduler (search for it in Start)
- Click Create Basic Task → name it Event Log Cleanup → Next
- Set the trigger: Monthly is usually appropriate for home computers. Weekly for computers that generate many events
- For the action, choose Start a program. Program:
wevtutil. Arguments:cl Application. This clears the Application log on schedule - To clear multiple logs, create a batch file that runs several wevtutil commands and schedule that batch file instead. For example, create a file called clear-logs.bat containing:
wevtutil cl Applicationwevtutil cl Systemwevtutil cl Setup
- If you want to archive before clearing, modify the batch file to export each log before clearing it
- Make sure the scheduled task runs with highest privileges (check Run with highest privileges in the task properties) — clearing Security and some other logs requires administrator rights
Fix Event Log service using high resources
If the Event Log service (svchost.exe hosting EventLog) is consuming high CPU or disk:
- Clear oversized logs: very large logs (hundreds of MB or several GB) make the Event Log service work harder. Clear or reduce the maximum size of the largest logs
- Reduce verbose logging: some applications and services write excessive log entries. In Event Viewer, check Applications and Services Logs for logs with very high event counts. You can disable individual operational logs by right-clicking them → Disable Log
- Check for circular logging problems: if a service is crashing and restarting repeatedly, it generates a constant stream of error events. Fix the underlying service problem to stop the logging flood
- Audit policy review: on computers with aggressive security auditing enabled (common in business environments), the Security log can generate thousands of events per hour. Review the audit policy in Local Security Policy → Advanced Audit Policy Configuration and disable any categories you do not need
Remote log management help
If you need help managing Event Viewer logs, setting up archiving, or diagnosing a log-related performance problem, Marion Remote Fix can assist remotely — configuring log retention, clearing and archiving logs, and optimizing log settings through a secure remote session.