Choose Apple menu > System Settings, then click General in the sidebar. (You may need to scroll down.) Click Transfer or Reset on the right, then click Erase All Contents and Settings.