How to Format an OS X Terminal Hard Disk

Written by liam rodom abraham
  • Share
  • Tweet
  • Share
  • Email

Occasionally your Mac OS X computer has trouble formatting a disk the usual way (i.e., through the Disk Utility). This guide is meant to provide an alternative means of formatting a disk that is far more reliable. We'll be using Terminal to type in commands directly to the computer, giving you a level of power and control that is unparalleled.

Skill level:


  1. 1

    Make sure the disk is connected to your computer (e.g., via USB) and powered on. Click on the magnifying glass in the upper right of your screen, and type "Disk Utility" (without quotes). Click on the first result.

  2. 2

    In the column on the left side of Disk Utility, click on the disk you'd like to format in Terminal. Underneath the left column, you will see the disk's "Mount Point" listed. Using your mouse, highlight the information after "Mount Point:" and press "Command C" to copy the information.

  3. 3

    Click on the magnifying glass in the upper-right corner of your screen. Type "Terminal" without quotes. Click on the first result.

  4. 4

    Type "diskutil erase Disk HFS+ newdisk" (without quotes). Press the Spacebar. Press "Command V" to paste in the mount point of the disk you're trying to format. Put double quotes (") around the mount point information you just pasted in. Your line should look something like this: diskutil erase Disk HFS+ newdisk "/Volumes/disk 1".

  5. 5

    Press Enter on your keyboard. You will receive a message letting you know when the formatting has successfully completed. Congratulations, you have just formatted a disk using Terminal!

Tips and warnings

  • Formatting removes all the data from a disk. Double-check that all important information has been backed up, and make sure you don't format the wrong disk!

Don't Miss

  • All types
  • Articles
  • Slideshows
  • Videos
  • Most relevant
  • Most popular
  • Most recent

No articles available

No slideshows available

No videos available

By using the site, you consent to the use of cookies. For more information, please see our Cookie policy.