Restore a deleted user on Mac
If you saved a deleted user’s home folder, you can restore the user and the user’s home folder.
The technique you use depends on whether you saved the home folder as a disk image or a regular folder.
Restore the home folder from a disk image
In the Finder on your Mac, choose Go > Go to Folder, enter /Users/Deleted Users, then click Go.
Open the disk image file for the deleted user’s home folder.
The disk image filename begins with the user’s account name and ends with .dmg.
The contents of the home folder appear in a new window.
Choose File > New Finder Window, then open the Users folder.
Press and hold the Option key while dragging the disk image icon for the deleted user into the Users folder, then enter an administrator name and password to proceed.
The deleted user’s home folder is copied to the Users folder.
Choose Apple menu > System Preferences, then click Users & Groups .
Open Users & Groups preferences for me
If the lock at the bottom left is locked , click it to unlock the preference pane.
Click the Add button below the list of users.
Click the New Account pop-up menu, then choose a type of user.
Enter a full name for the user.
If necessary, edit the account name so it matches the name of the deleted user’s home folder.
An account name is generated automatically.
Enter a password for the user in the Password and Verify fields, then enter a hint to help the user remember the password.
To use the Password Assistant, click the key next to the Password field. See Tips for creating secure passwords.
Click Create User.
Click Use Existing Folder.
Restore the home folder from a saved folder
In the Finder on your Mac, choose Go > Go to Folder, enter /Users, then click Go.
The deleted user’s home folder is in the /Users folder, and its name is the same as the user’s account name, followed by (Deleted).
Rename the deleted user’s home folder by removing (Deleted), so that the folder name exactly matches the account name of the deleted user.
You may be asked to enter your administrator name and password before you can rename the folder.
Follow steps 4 through 12 of Restore the home folder from a disk image.
After restoring a user from a saved home folder, you can select “Allow user to administer this computer.”