How do I make a recovery partition for my Mac in El Capitan? The tool I used for Mavericks isn't compatible with later versions of OS X. 

Generally speaking, you don't need to create a recovery partition for your Mac: since the launch of OS X Lion - because at this point Apple stopped selling boxed copies of its operating systems, so it knew buyers wouldn't have backup install disks - Mac OS X has offered a built-in recovery partition that is created automatically for you during installation and stored in a hidden section of the hard drive. (This is what enables you to recover a failed Mac by holding Command + R during startup, which will take you into Recovery Mode.)

Sometimes, however, for one reason or another, the partition is not created during the installation process. In these cases you can create your own. And we show you how to do this in the following article. As noted above, the free tool that widely used for this purpose in OS X Mavericks and earlier is not compatible with El Capitan and Yosemite, so we'll start by walking you through a method that works with OS X 10.10 and 10.11 (in very slightly different ways).

(There are also occasions when a recovery partition won't help. One is when the hard drive itself - where the recovery partition is stored - fails catastrophically. In that case you'll need a recovery disk stored on a removable storage medium. We've got a separate article showing how to create a Mac recovery disk.)

Read next: How to reset a Mac: restore your Mac to the original factory settings

How to create Mac recovery partition in OS X El Capitan: Do a clean install of OS X

Generally the best and simplest method is to reinstall OS X entirely. This is a neat way of triggering for a second time the process whereby the recovery partition is created. It's quite a drastic and time-consuming approach, however.

Here's how to do a clean install of El Capitan. You'll need an 8GB or larger removable drive that hasn't got anything on it you need, and admin privileges.

1. Back up. Full instructions here: How to back up a Mac. See also: Best Mac backup software.

2. We're going to redownload the installer file for El Capitan and store it on a removable drive: get yourself a USB flash drive with a capacity of at least 8GB. (We're going to erase it, so make sure it doesn't contain any valuable data.)

The drive you use must be formatted as a Mac OS Extended (Journaled) volume with a GUID Partition Table. To format the drive, go to Applications > Utilities and open Disk Utility. Select the drive and click Erase. (The name of the disk needs to be "Untitled", if the Terminal commands below are to work, so rename it if necessary.) Select Mac OS Extended (Journaled) as the format type. Click Erase.

3. Go to the Mac App Store and search for El Capitan (or just click here). Click Download. Since we've already got OS X 10.11.1, we get a warning message: 'Would you like to continue?' We'll click Continue. Enter your Apple ID and password. The installer is about 6GB, so downloading can take a while.

How to create a Mac recovery partition

4. When it's finished downloading the installer will launch automatically, but we don't want to use it yet, so press Apple + Q (or rather Command + Q) to quit out of the installer. Find the installer file (which should have appeared in the Applications folder) and save it to an external flash drive.

5. Next we need to create a bootable USB disk so that we can install a new copy of El Capitan on the Mac from the flash drive. We've got full instructions on how to do that here - How to make a bootable Mac OS X install drive -  but we'll run through the basics again. We're going to create the bootable drive using Terminal.

Connect the removable drive to your Mac, and make sure it's called Untitled - rename it if necessary. Make sure the El Capitan installer (or at least a copy of it), called Install OS X El Capitan.app, is in its default location in your main Applications folder (/Applications).

Select the text of the following Terminal command and copy it (Apple + C, or Command + C):

sudo /Applications/Install\ OS\ X\ El\ Capitan.app/Contents/Resources/createinstallmedia --volume /Volumes/Untitled --applicationpath /Applications/Install\ OS\ X\ El\ Capitan.app --nointeraction

Go to Applications > Utilities and double-click Terminal to launch it. Paste (Command + V) the copied command into Terminal and hit Return. Type your admin-level account password when prompted, and press Return again.

If you see the message 'To continue we need to erase the disk at /Volumes/Untitled. If you wish to continue type (Y) then press return', type Y and press Return; if not, don't worry. When the procedure is finished (it can take anywhere from a couple of minutes to half an hour), you'll see Copy Complete and Done, as shown in the screenshot below (which comes courtesy of my colleague Dan Frakes). You're finished.

How to create a Mac recovery partition

6. Now we'll install a fresh copy of El Capitan from the installer drive.

With the boot drive connected, start up - or restart - your Mac while holding down the Option key (also known as Alt). This will take you to Startup Manager. Choose to install OS X El Capitan from the drive. Select 'Disk Utility' and your hard drive, then click Erase. Go back to the main menu and choose Install OS X.

Once installation of El Capitan is complete, you can restoring apps and settings from a Time Machine backup, or download them again manually.

How to create Mac recovery partition in OS X Yosemite: Do a clean install

If you're using Yosemite, we can use the same method as above, but it's a bit harder to get the install file: Apple doesn't offer downloads of outdated OS versions through the normal store front, and searching for 'Yosemite' won't find what you're looking for.

Make sure you're logged into the Mac App Store with the Apple ID you used to update to Yosemite, then click Purchased in the menu bar along the top. Scan down the list of apps you've purchased or download for free (which is in order of when you downloaded them) and find Yosemite.

How to create a Mac recovery partition in Yosemite

Click download and then follow the procedure listed above for El Capitan.

How to make a Mac recovery partition in OS X Mavericks and earlier

The steps above apply to the two most recent versions of Mac OS X, but there are script tools available that make the process easier if you're running something earlier. Christopher Silvertooth created a tool called Recovery Partition Creator; the most recent version of this, 3.8, is compatible with Mavericks, but sadly will not work with anything later than that.

If you're running Mavericks (or earlier), follow these steps to create a recovery partition:

1. Make a backup.

Recovery Partition Creator modifies your hard drive in order to create the recovery partition, and this is potentially hazardous. We don't expect any problems, but it's wise before we begin to back up your Mac.

2. Get a copy of the installer file for your version of OS X.

This works the same as step 2 above. Go to the Mac App Store, find the relevant version of OS X, and click download. The install file should appear in your Applications folder.

3. Download Recovery Partition Creator 3.8.

Download Recovery Partition Creator - which is available for free here. Unzip the install file and double-click the icon.

How to create a Mac recovery partition

Depending on your security settings, OS X may refuse to open the app "because it is from an unidentified developer". We've had no problems with the software but you'll have to make your own decision.

If you're willing to take the plunge, go to System Preferences > Security & Privacy, and either set 'Allow apps downloaded from' to 'Anywhere' (not recommended) or click 'Open Anyway' next to the warning message about Recovery Partition Creator, which just bypasses the security measure for this case. You'll get one more warning message and chance to change your mind: click Open.

How to create a Mac recovery partition

4. Set the app to work.

Clicking Open at the end of the last step immediately triggers an alarming-looking warning: "the program you are about to run will modify your hard drive… It is recommended that you backup all of your data". We backed up in step 1, so we're happy to click OK and proceed.

How to create a Mac recovery partition

5. Follow the instructions as the app proceeds.

From here on in the app is pretty self-explanatory. You'll need to select a drive to store the recovery files; agree to check the disk for errors (we recommend this, rather than skipping this step); locate the install file we downloaded in step 2; and select the correct option when asked if you've got either Mac OS X version "10.7 or 10.8", or "10.9".

Read next: El Capitan tips