To erase a Macintosh hard disk you can boot with a different disk and use the Disk Utility.
For OS X 10.2-10.7:
|Note:This refers to a full Mac OS X 10.2.3 or later CD included with a computer, not to the update-only 10.2.3 CD.Steps for zeroing data
These steps assume you have a Mac OS X 10.2.3 or later CD:
For a more secure method of erasing of data, you can select the checkbox “8 Way Random Write Format” instead of or in addition to selecting “Zero all data.” This process could take several hours.
For OS 10.8 and newer:
Secure Erase is documented in the Help menu of the Disk Utility application. Disk Utiltiy has shipped on all OS X versions in /Applications/Utilities folder.
To erase your computer’s startup disk, you must start up from another disk, such as an OS X installation disc or from the Recovery Disk. All new OS devices come with a built-in Recovery Disk which can be used by restarting and holding down the R key. A Recovery Disk can also be created on an external hard disk or thumb drive using the Recovery Disk Assistant:
Securely erase a disk in OS X 10.8 or newer
The following is a summary of the Disk Utiltiy help available from the Help menu when running the Disk Utility application:
You can securely erase a disk or partition to make sure the confidential information it contains cannot be recovered.
When erasing a disk or partition, Disk Utility does not erase the actual files; it erases only the information used to access the files. Many commonly available disk recovery apps can easily recover the files. When securely erasing a disk or partition, Disk Utility writes over the erased files, so they can never be recovered. You can choose how many times to write over the files. Writing over the files several times is more secure than writing over them once, but it takes longer.
Securely erasing a disk erases files on all its partitions. Securely erasing a partition erases all the files on that partition but does not affect other partitions.
You can’t securely erase a CD, DVD, or a solid-state drive. If you don’t want data recovered from a solid-state drive, use full disk encryption.
To erase your computer’s startup disk, you must start up from another disk, such as an OS X installation disc or from the Recovery Disk .
Also for those wanting to “Clean” individual files, note this section from the technote:
Mac OS X 10.3+ feature – Secure Empty Trash
You can securely empty the Trash in Mac OS X Panther. While in the Finder, from the File menu choose Secure Empty Trash.
Note: When you securely empty the Trash, the deleted data cannot be recovered by disk utilities. You should only do this if you have a backup or you are sure you will never need the data again.
For machines which boot only MacOS 9 or less use either Drive Setup, Apple HD SC Setup, or Internal HD Format and select the option to zero out and/or low level format the disk. These programs are usually in the Utilties Folder on the install CDs for the various versions of the MacOS.