Performin factory reset on your macOS can solve many problems, if you are simply looking to fix a misbehaving Mac, or if you are selling, resetting it to factory settings and wiping it will allow you to set it up like a new Mac. This tutorial will show you how to factory reset a Mac, an iMac or MacBook Pro.
Before you erase your Mac, make sure your Mac is currently connected to the internet and plug in the power adapter, so there's no danger of running out of battery power. You should back up your computer, disable some features and services, and then go on booting to Recovery Mode and using Disk Utility to erase (format) a hard disk and reinstalling macOS.
Resetting a Mac to factory settings deletes all the data stored on that device, you can make a backup of the data using Time Machine software Apple provides - Here's how to back up using Time Machine.
If your computer has not been updated to Catalina, you will need to deauthorize your computer from the iTunes app.
Open iTunes. From the menu bar at the top of your computer screen or at the top of the iTunes window, choose Account > Authorizations > Deauthorize This Computer.
When prompted, enter your Apple ID and password. Then click Deauthorize.
Choose Apple menu > System Preferences, then click Apple ID.
Choose iCloud in the side panel and Turn off Find My Mac.
Then select Overview in the side panel and click Sign Out.
If you have macOS Mojave or earlier, choose Apple menu > System Preferences, click iCloud, and then Sign Out.
A dialog asks whether you want to keep a copy of your iCloud data on the Mac. Because you'll reformat the hard drive in a later step, just click Keep a Copy to proceed.
FileVault encrypts the files on your hard drive. It's not on by default, but if it is being used then it's advisable to turn it off before going factory reset your Mac.
If you have a used Mac, or plan to sell an older version of Mac, you need to reset the device to default settings. But what if you don't know the password? You can use the following steps to reset the factory settings and reinstall macOS.
1. Click the Apple logo at the top left of the screen and select Restart.
2. Immediately hold down the Command + R keys until you see an Apple logo or spinning globe.
3. It will take a while for the Mac to start up in this mode.
4. You may see a screen asking you to choose a language.
5. The next screen you'll see is the Recovery Mode utility window.
1. Select Disk Utility from the Utilities window in macOS Recovery. Then click Continue.
2. You should see two disks - Macintosh HD and Macintosh HD - data in Catalina, you first need to delete the Macintosh HD-Data partition before erasing your main hard drive.
Click on this Macintosh HD - Data drive to select it.
Then choose Edit > Delete APFS volume from the menu bar.
When you're asked to confirm, click the Delete button.
3. After deleting any Data volumes, select Macintosh HD in the sidebar.
Select Reinstall macOS from the utility and follow the instructions that appear to reinstall macOS. Your Mac will start downloading and installing Catalina or any version of macOS your Mac is running. The Mac will then restart and at the end you will see the Welcome screen. If you want to continue using your Mac, follow these steps to set it up.