Time Machine is OS X’s built in backup function. Like most things Apple, it’s super simple to set up and foolproof to use. In this tutorial I’ll show you all you need to know to start using Time Machine as part of a solid backup plan. I’ll cover setting up a Time Machine drive, restoring individual files and restoring the entire system. If you own a Mac and aren’t using Time Machine, this tutorial is for you.
Introducing Time Machine
Time Machine works by backing up every file on your Mac—including things like applications and preferences—to an external hard drive. The only thing not backed up is the operating system. If anything happens to your Mac, you can go back to the copy stored in Time Machine.
Time Machine also has a versioning system. As well as backing up every file, Time Machine backs up a snapshot of how your Mac’s system file structure. These system snapshots are backed up too and you can revert your entire Mac, or an individual file or folder, back to exactly how it was an hour, a week or even months ago. If you accidentally delete a file on your Mac, the most recent Time Machine snapshots won’t show it, however, one from a week or a month will still have it.
Tip: Time Machine stores hourly backups for twenty-four hours, daily backups for a month and weekly backups indefinitely, limited only by the capacity of the storage being used.
What You'll Need
Time Machine backs up the Mac to an external hard drive. Any USB, or Thunderbolt, drive will work, so long as it is at least the same size as the Mac’s hard drive.
If you would rather backup wirelessly, Apple sells the AirPort Time Capsule—a router with a built-in hard drive—specifically for this purpose. So long as your Mac is connected to the Time Capsule’s network it will appear like any other drive when you are setting up Time Machine.
Tip: Due to Time Machine’s versioning system, backups can get quite large. Although you can use a smaller hard drive, it is best to use the highest capacity drive you can get your hands on.
Setting Up Time Machine
Time Machine is simple to set up. If you don’t have a Time Machine backup configured, connecting an external hard drive to your Mac will result in a dialogue box asking if you want to use it for Time Machine backups. Select Use as Backup Disk to start backing up.
If, for some reason, you don’t get the dialogue box, or you want to configure an additional Time Machine device, navigate to the Time Machine preference pane in System Preferences. Click on Select Disk… and select the hard drive, or Time Capsule, you want to use from the menu and then click Use Disk. Time Machine will start backing up straight away.
Tip: The first Time Machine backup will require the most time. It can take several hours for all the files to be transferred. The best thing to do is leave the Mac backup over night.
To encrypt the Time Machine backups check Encrypt Backup Disk when you configure your external drive. You will be prompted to set up a password. If you try to access the files stored in the Time Machine, or restore the whole system, you will need to enter that password again.
Backing Up the System
To back up a Mac to a Time Machine, just connect it to the hard drive. OS X will automatically detect the Time Machine and begin backing up files. If you don’t backup your Mac for more than ten days it will start notifying you.
So long as you are connected to the Time Machine drive—whether over a cable or because you are connected to a Time Capsule network—the Mac will be back up hourly. If you want to force the Mac to backup, click on the Time Machine menubar icon and select Back Up Now.
Restoring a File or Folder From Time Machine
To restore a single file from Time Machine, connect the Time Machine and the Mac.
Open a new window in Finder. Browse to the Applications folder and open the Time Machine app or click on the Time Machine menubar icon and select Enter Time Machine. Time Machine will start up displaying your home folder in a Finder window.
You can use the timeline or the forward and backwards arrows to move through the system snapshots stored in Time Machine. Navigate around the file system using the Finder window as you normally would.
For example, if you want to restore a file that was in the Downloads folder last week, use the arrows or the timeline to go to a snapshot from that week and then navigate to the Downloads folder in the Finder window.
Select the file and click on the Restore button. It will now be restored to the same folder it was in. You can also restore folders using the same method.
Tip: If you don’t know where a file is in the Time Machine, you can use Spotlight to search as normal.
Restoring the System From Time Machine
Restoring the whole system from a Time Machine backup is equally simple, although it takes a lot more time. My fellow Tuts+ author, Connor, has written a full tutorial that goes into depth on OS X’s system recovery options. If you are in the unenviable situation of having to restore a Mac I suggest you read his tutorial in full.
Briefly, connect the Time Machine drive to the Mac and System Recovery by holding Command-R while the Mac boots. Select Restore From Time Machine Backup from the recovery menu. If you have encrypted the drive, you’ll need to enter the password now. Follow the onscreen prompts and after a few hours your system will be restored to how it was during the most recent backup.
The Pros and Cons of Time Machine
Time Machine is a great first line of defence. It’s very simple to set up and its versioning system can save you if a file gets corrupted or you accidentally delete it. It’s also great for recovering all the applications, files and preferences if the Mac needs to be restored.
Time Machine, however, should be just one part of a foolproof backup solution. If the house is broken into, or electronics are damaged by a natural disaster, you might find yourself without a Mac and without a backup.
In this tutorial I’ve shown you everything you need to know to get started using your Mac’s built-in backup app, Time Machine. It is one of the most user friendly backup systems available. All Mac users should be using it.
Time Machine, however, should only be one part of a larger backup solution. Too many Mac users rely solely on Time Machine and are still at risk of data loss.