Factory Reset as a Last Resort for a Locked Laptop
A factory reset wipes your laptop back to its original state — the same condition it was in when it left the factory — and removes the password that is locking you out. This is different from a regular restart. The reset erases all your files, programs, and settings, so use this only when you cannot recover the password through other means and you have already backed up anything you need to keep.
The method depends on whether you have a Windows or Mac laptop, and whether you can still reach the login screen or are completely locked out. Some paths require a second device or a USB drive. Others work directly from the locked screen.
Key Takeaways
- A factory reset erases everything on your laptop, so back up any files you need before starting.
- Windows and Mac have different reset processes, and the steps change depending on whether you can reach the login screen.
- You may need a second computer or a USB drive to complete the reset, depending on your situation.
- After the reset completes, you will set up the laptop as if it were brand new, including creating a new password.
- If you cannot reach the login screen at all, you may need to contact the laptop manufacturer or a technician.
Factory Reset on Windows When You Can Reach the Login Screen
If your Windows laptop is showing the login screen but you do not know the password, you can reset it from that screen without needing another device. Look for a link that says "Reset password" or "I forgot my password" — this appears below the password field on most Windows 10 and Windows 11 machines. Click it.
Windows will ask you security questions you set up when you created the account, or it will send a code to a recovery email address or phone number you provided during setup. Answer the questions or retrieve the code, and Windows will let you create a new password. Once you set the new password, you can log in normally.
If you do not see a reset link on the login screen, or if the security questions do not work because you do not remember the answers, move to the next section.
Factory Reset on Windows Using Another Computer
If the password recovery link does not work, you will need a second computer and a USB drive with at least 8 gigabytes of space. On the second computer, read the Windows installation media from Microsoft's website. Insert the USB drive, run the media creation tool, and follow the prompts to write Windows installation files to the drive.
Insert the USB drive into your locked laptop and restart it. As the laptop boots, press the key that opens the boot menu — usually F12, F2, Esc, or Del, depending on the manufacturer. Select the USB drive from the menu. The Windows installer will start. When you reach the screen that asks where to install Windows, look for a link or button labeled "Repair your computer" or "Troubleshoot." Click it.
From the troubleshooting menu, select "Reset this PC" and choose "Remove everything." Windows will erase the drive and reinstall itself. When the installation finishes, you will reach a setup screen where you create a new account and password from scratch. Your old password no longer exists.
Factory Reset on Mac When You Can Reach the Login Screen
On a Mac, if you can reach the login screen, click the question mark icon or look for a "Reset Password" option. Mac will ask you to answer security questions or verify your identity through a recovery key or Apple ID. If you have access to the Apple ID and password you used to set up the Mac, you can use those to reset the account password.
If you do not have the Apple ID password or recovery key, you will need to move to the next section.
Factory Reset on Mac Using Recovery Mode
Restart your Mac and when ready hold down Command and R together until you see the Apple logo or a spinning globe. This boots the Mac into Recovery Mode. When the macOS Utilities window appears, select "Erase Mac" or "Reinstall macOS," depending on your macOS version.
Choose "Erase" to wipe the drive completely. macOS will ask you to sign in with an Apple ID — use the one associated with the Mac. If you do not know the Apple ID or password, you cannot proceed this way. Once you sign in, macOS will erase the drive and reinstall the operating system. When setup completes, you will create a new account and password.
If you do not know the Apple ID associated with the Mac, contact Apple Support or visit an Apple Store with proof of ownership. They can help you regain access.
What Happens After the Factory Reset
After the reset finishes and the operating system reinstalls, your laptop will boot into a setup screen. You will be asked to choose your language, connect to Wi-Fi, and create a new user account with a new password. This new account is separate from the old one — the old account and all its files are gone.
Once setup is complete, your laptop works normally. You can install programs, create files, and use it as usual. If you had files on the old account that you did not back up before the reset, they cannot be recovered through normal means. This is why backing up before a factory reset is critical.
When You Cannot Reach the Login Screen at All
If your laptop will not start, shows only a black screen, or is stuck on a manufacturer logo, a factory reset from the operating system is not possible. In this case, you have two options: contact the laptop manufacturer's support line with proof of ownership, or take the laptop to a repair technician who can access the drive directly or perform a more advanced reset.
Manufacturers like Dell, HP, Lenovo, and Apple have support teams that can walk you through advanced recovery steps or direct you to a service center. Have your laptop's serial number ready — you can usually find it on a sticker on the bottom or back of the device.
Frequently Asked Questions
Will a factory reset remove viruses or malware?
Yes. A factory reset erases the entire drive and reinstalls the operating system, so any malware is removed. However, if the malware is on an external drive or USB device you connect afterward, it can return. After resetting, avoid downloading files from untrusted sources and keep your antivirus software up to date.
Can I recover files after a factory reset?
Once the reset completes and you reinstall the operating system, recovery is very difficult. Data recovery services exist but are expensive and not always successful. This is why backing up important files before a reset is essential. If you did not back up, a data recovery service may be your only option.
Do I need the original Windows or Mac installation disc?
No. Windows and Mac can both be downloaded and installed from USB drives using free tools from Microsoft and Apple. You do not need to purchase anything. You will need a second computer and a USB drive to create the installation media.
What if I forget the new password I create after the reset?
Set up password recovery options during the initial setup — a recovery email, phone number, or security questions. If you forget the new password, you can use these options to reset it without doing another factory reset. Write down your new password in a safe place.
How long does a factory reset take?
A factory reset usually takes between 30 minutes and two hours, depending on your laptop's speed and drive size. Do not turn off the laptop during the process. Plug it in and let it run until you see the setup screen.