Find Previous Computer Name Windows
In this article
Yes, you can find a previous computer name in Windows by checking system logs or registry entries that store historical computer name data. This is useful when troubleshooting network conflicts, tracking device changes in an organization, or recovering from a rename error. You don’t need third-party software—Windows logs this information internally, though it’s not immediately visible in standard settings.
What You'll Need
- A Windows PC with administrator access
- Access to the Event Viewer or Registry Editor
- Optional: Command Prompt or PowerShell for advanced users
Step-by-Step
- Press Windows + R to open the Run dialog box. Type
eventvwr.mscand press Enter to launch Event Viewer. - In Event Viewer, navigate to Windows Logs > System in the left-hand pane.
- In the right-hand Actions pane, click Filter Current Log.
- In the Filter dialog, locate the Event IDs field. Enter
19and press OK. This filters system events related to computer name changes. - Review the filtered list. Look for events with the source Microsoft-Windows-ComputerName. These entries appear whenever the computer name was changed.
- Double-click an event to open its details. In the General tab, read the description. It typically states: "The computer name has been changed from 'old-name' to 'new-name'".
- Record the previous name from the log. If multiple events appear, sort by date (newest first) to trace the naming history.
- Alternatively, open Registry Editor by typing
regeditin the Run dialog. Navigate toHKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters. - Look for the string values
HostnameandComputerName. These reflect the current name. For older names, checkPreviousComputerNameif it exists—some systems create this entry during a rename. - For deeper history, navigate to
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\ComputerName\ComputerNameandActiveComputerName. TheComputerNamesubkey may retain a prior value if the system hasn’t fully updated. - Use Command Prompt to run
systeminfo | findstr /C:"Host Name"to confirm the current name, then cross-reference with logs. - If Event Viewer shows no results, the logs may have been cleared. Try restoring from a system backup or check Group Policy logs if on a domain.
Common Mistakes
- Confusing computer name with username or workgroup name. The computer name is the device identifier on a network.
- Not running Event Viewer or Registry Editor as administrator—some logs and keys are restricted.
- Assuming the
PreviousComputerNameregistry entry always exists. It’s only created during certain rename operations, not all. - Overlooking Event ID 19. Some users search for generic terms like "rename" instead of using the correct event identifier.
- Editing the registry without backing it up first. Accidental changes can affect system stability.
Tips
- Export Event Viewer logs regularly if tracking device changes in a business environment. Right-click the log and select Save All Events As.
- Use PowerShell to automate checks:
Get-WinEvent -LogName System | Where-Object Id -eq 19returns all rename events. - On domain-joined PCs, check Active Directory logs via Group Policy or domain controller event logs for additional rename tracking.
- If the computer was renamed recently, check the System log date range carefully—older entries may be archived.
- Always verify the current computer name via Settings > System > About to ensure accuracy before and after checking logs.
Troubleshooting
If no rename events appear in Event Viewer, the logs may have been cleared due to system updates, disk cleanup, or policy settings. Try restoring from a system restore point if available. If you’re on a network, contact your administrator—domain policies may override local logs. If Registry Editor lacks PreviousComputerName, the system did not generate it during the last rename, which is normal for some Windows versions. In such cases, only Event Viewer or backup logs can help. If access is denied in Event Viewer or Registry, ensure you’re logged in as an administrator and User Account Control (UAC) is not blocking access. Temporarily disable third-party security software if it interferes, but re-enable it immediately after. If the PC was reimaged or reset, historical names are likely lost unless backed up externally.
Frequently Asked Questions
Can I find a previous computer name without administrator rights?
No, accessing system logs and registry keys requires administrator privileges. Standard users cannot view these entries.
Does every computer name change leave a log entry?
Yes, if the change was made through standard Windows settings and the system was running normally. However, logs may be lost after a reset, reinstall, or if Event Log settings purge old entries.
Is the previous computer name stored in the registry by default?
Not always. Windows may create a PreviousComputerName entry, but it’s not guaranteed. Event logs are more reliable.
Can I recover a computer name from a backup?
Yes, if you have a system or registry backup from before the rename, you can restore or browse it to find the old name.
What if the computer was renamed multiple times?
Event Viewer will show each change as a separate Event ID 19 entry. Sort by date to reconstruct the full naming history.
Does renaming a computer affect network access?
Temporarily, yes. Other devices may fail to connect until DNS or NetBIOS updates propagate. Always update network references after a rename.