Raspberry Pi with SSD

Boot Raspberry Pi from SSD: Connect a USB SSD, SATA or NVMe the Right Way

To make your Raspberry Pi boot from SSD, start with your model, because it decides which kind of SSD fits: a ready-made USB SSD, a 2.5-inch SATA SSD on a USB adapter or an NVMe SSD, either in a USB enclosure or on an add-on board on the Pi 5. An SSD handles more writes in continuous use than a microSD card. From the Pi 4 onwards it adds speed as well, most of all with NVMe on the Pi 5 (documented figures).

Quick answer: which SSD for which Pi?

Raspberry Pi 4 and 400: a USB SSD in one of the blue USB 3.0 ports, either bought ready-made or as a 2.5-inch SATA SSD on a USB adapter. NVMe only works in a USB enclosure, because the Pi 4 has no PCIe connector.
Raspberry Pi 5: the fastest option is an NVMe SSD on the M.2 HAT+ (2230 or 2242 format), otherwise USB as on the Pi 4. Raspberry Pi recommends the 27 W power supply, because on a 3 A supply the Pi 5 blocks booting from USB.
Raspberry Pi 500: USB only, like the Pi 4. On a 3 A supply, its USB devices only get 600 mA.
Raspberry Pi 500+: the NVMe SSD is already built in.
Raspberry Pi 3: USB 2.0 only. An SSD adds durability there, but no speed.
Hard drives and multiple drives: only on a USB hub with its own power supply.

This article is about choosing and connecting the SSD: USB SSD, SATA SSD on an adapter and NVMe. What your model needs to boot from USB in the first place (OTP bit, bootloader, boot order, power supply on the Pi 5) is covered in our guide Raspberry Pi USB Boot.

Which SSD fits which Pi?

There are three types of SSD and four ways to connect them. A USB SSD is a ready-made external SSD with a USB cable. A SATA SSD is the 2.5-inch type used in laptops and needs a USB-SATA adapter. An NVMe SSD is a slim stick in the M.2 format that transfers data over the PCIe interface. It runs either in a USB enclosure or, on the Pi 5, directly over PCIe. A USB SSD and an NVMe SSD in a USB enclosure connect the same way, so option 1 covers both. The last column shows the maximum current the Pi supplies to all USB devices combined.

ModelUSB SSDSATA SSD on adapterNVMe in USB enclosureNVMe over PCIeTotal USB current
Raspberry Pi 3B, 3B+yes, USB 2.0yes, USB 2.0yes, USB 2.0no1.2 A
Raspberry Pi 4, Pi 400yesyesyesno1.2 A
Raspberry Pi 5yesyesyeswith M.2 HAT+1.6 A, 600 mA on a 3 A supply
Raspberry Pi 500yesyesyesno1.6 A, 600 mA on a 3 A supply
Raspberry Pi 500+yesyesyesbuilt in1.6 A
Source: Raspberry Pi documentation, sections “USB mass storage boot”, “Power supply” and “M.2 HAT+”

The Pi 3B only boots from USB after you have set its OTP bit once. This is a setting in the chip that can only be set once and never cleared. The 3B+ boots from USB out of the box. Which other models boot from USB is listed in the overview of our USB boot guide.

How much faster is the SSD?

How fast the system feels depends less on large copy rates than on the many small accesses it makes to load programs and write logs. These are measured in IOPS, input/output operations per second on 4 KB blocks. The table collects documented values: our own NVMe measurement and Raspberry Pi’s figures for its SD card and its SSD.

StorageMetricValueSource
NVMe on the Pi 5, PCIe 2.0 (default)sequential read / write439 / 429 MB/sour measurement, Intenso Premium 250 GB
NVMe on the Pi 5, PCIe 3.0 (not certified)sequential read843 MB/sour measurement, same SSD
Raspberry Pi SSD 256 GB on the Pi 54K random read / write40,000 / 70,000 IOPSRaspberry Pi documentation
Raspberry Pi SD card on the Pi 54K random read / write5,000 / 2,000 IOPSRaspberry Pi documentation
Raspberry Pi SD card on the Pi 44K random read / write3,200 / 1,200 IOPSRaspberry Pi documentation
USB SSD on USB 3.0 (Pi 4, Pi 5)interface limit500 MB/s in theory, less in practiceUSB 3.0 specification (5 Gbit/s)
Measurement: Raspberry Pi 5 NVMe SSD boot. Values come from different sources and methods; read them as orders of magnitude.

Going by Raspberry Pi’s own figures, its 256 GB SSD manages about eight times as many small-block reads as its SD card on the Pi 5, and around 35 times as many writes. We have no measurement of our own with a USB SSD. For the Pi 4, which connects SSDs only over USB, we therefore cannot give a documented figure, only the USB 3.0 limit.

On the Pi 3, an SSD brings no speed gain. It only has USB 2.0, so a USB SSD is barely faster than a good microSD card there. The benefit is durability.

What you need

Links marked with * are affiliate links, which makes them advertising. If you buy through one, I earn a commission at no extra cost to you. As an Amazon Associate I earn from qualifying purchases. Learn more

Option 1: a ready-made USB SSD or NVMe in a USB enclosure

A USB SSD plugs straight in. On the Pi 4, Pi 5, Pi 400 and Pi 500 it belongs in one of the blue ports, because only those are USB 3.0. The USB 2.0 ports throw away most of the speed. On the Pi 4 and Pi 5 they are black; on the Pi 400 and Pi 500 it is the single white port. If the SSD has a USB-C plug, you need a cable or adapter to USB-A, since the Pi only has USB-A ports for drives.

Many USB SSDs, including the SanDisk SSD from the list above, contain an NVMe SSD inside. To the Pi it is still an ordinary USB drive. Manufacturer figures such as “up to 1,050 MB/s” apply to faster USB ports on a PC; on the Pi, USB 3.0 caps the speed. The same goes for an NVMe SSD you fit into a USB enclosure yourself. On the Pi 4, that is the only way to use an NVMe SSD.

Before you write the operating system to the SSD, test it on a Pi running from its SD card. Plug in the SSD and open a terminal:

lsblk

The SD card shows up as mmcblk0, the SSD with its size, usually as sda; a second USB drive would be sdb. If it appears there as a drive, it also works under Linux, and booting from it usually works too. If it is missing, try another cable or port before you continue.

Option 2: a SATA SSD on a USB adapter

If you have a 2.5-inch SSD from an old laptop, all you need is a USB-SATA adapter: a short cable with a SATA connector on one end and USB-A on the other. Connect it as in option 1.

What matters is the chip in the adapter. Fast adapters support UAS (USB Attached SCSI), a transfer mode that Linux prefers; product descriptions usually call it UASP. According to the Raspberry Pi documentation, some adapters work with the bootloader but fail as soon as Linux switches to UAS mode: the Pi starts booting and then hangs. So test the SSD on its adapter first with lsblk on a Pi running from its SD card, as described in option 1. If an adapter causes trouble, you can switch off UAS for that specific device. The section “It still won’t boot” in our USB boot guide shows how.

SATA SSDs also come in the M.2 format. They look like NVMe SSDs but speak SATA. They need a USB enclosure that explicitly supports M.2 SATA, because NVMe-only enclosures do not recognise them. For the Pi 4 there is also the Argon ONE M.2*: according to the manufacturer, this case holds an M.2 SATA SSD in its base and connects it via USB.

Option 3: NVMe on the Pi 5 over PCIe

On the short edge opposite the USB ports, the Pi 5 has a PCIe connector for a flat ribbon cable. It connects to an add-on board (HAT) with an M.2 slot that holds the NVMe SSD. The number after the format gives the SSD’s width and length in millimetres: 2230 is 22 mm wide and 30 mm long, 2280 is 80 mm long.

  • Official M.2 HAT+: takes SSDs in the 2230 and 2242 formats. The Active Cooler, the official clip-on heatsink with fan, fits underneath. The HAT+ itself only fits the official Pi 5 case with the lid and fan removed.
  • M.2 HAT+ Compact: 2230 only, but it fits around the fan of the official case. You cannot mount an Active Cooler underneath.
  • Boards from other manufacturers: a 2280 SSD needs one of these, for example the Pimoroni NVMe Base*, which takes 2230 to 2280 according to the manufacturer. If a board does not follow the HAT+ specification, you enable the PCIe connector with dtparam=pciex1 in config.txt and, for booting, add PCIE_PROBE=1 to the bootloader configuration. How to add PCIE_PROBE=1 is shown in the NVMe section of the USB boot guide.
* Affiliate links (advertising). Learn more

NVMe only, no M.2 SATA: Raspberry Pi describes the HAT+ as being for NVMe drives and other PCIe devices. An M.2 SATA SSD may physically fit the slot, but it will not be detected as a drive there. When buying, look for “NVMe” or “PCIe” in the product name.

Speed and power: officially, the Pi 5 talks to the SSD over a single PCIe 2.0 lane, which means a maximum of 500 MB/s. PCIe 3.0 can be enabled in raspi-config under A8 PCIe Speed, but Raspberry Pi has not certified it and it may be unstable. The HAT+ supplies the SSD with up to 3 A from the Pi. The documentation describes the lock on a 3 A supply only for booting from USB and says nothing about NVMe. So use the 27 W power supply for NVMe as well.

The Pi 500+ already has an NVMe SSD built in; the Pi 500 has no usable PCIe connector. How to mount the HAT, set up the system and what speeds to expect is covered in our guide Raspberry Pi 5 NVMe SSD boot. Our NVMe HAT overview and NVMe buying guide compare boards and SSDs.

Is there enough power? SSDs, hard drives, multiple drives

The current limits in the table above apply to all USB devices combined. Raspberry Pi gives no guideline figure for SSDs; check your SSD’s datasheet for its requirement.

  • Pi 5 and Pi 500 on a 3 A power supply: if they do not detect a 5 A supply, both limit USB to 600 mA. What this means for booting from USB is covered under Check the requirements.
  • 2.5-inch hard drives (HDD): according to Raspberry Pi, they usually need a USB hub with its own power supply. Without one, you risk intermittent failures even if everything appears to work. 3.5-inch hard drives only run with their own power supply anyway.
  • Multiple drives: from the second drive on, the documentation says you typically need extra power, i.e. a powered hub or an enclosure with its own power supply.

Why a hard drive without its own power supply cuts out on the Pi is explained in USB hard drive without external power. How to mount a hard drive as a data drive is shown in Raspberry Pi USB hard drive setup.

Get the system onto the SSD and boot

First, check on the Pi that still runs from its SD card whether your model is ready. Then install a fresh system or move your configured system over from the SD card.

Check the requirements on the Pi

  • Pi 4 and 400: the bootloader must be from September 2020 or newer. sudo rpi-eeprom-update shows the date under CURRENT. How to update it is in the Pi 4 section of the USB boot guide.
  • Pi 5 with the M.2 HAT+: the bootloader must be from 6 December 2023 or newer. sudo rpi-eeprom-update also shows the date under CURRENT. If it is older, first update the system with sudo apt update && sudo apt full-upgrade. Then sudo rpi-eeprom-update -a and a reboot bring the bootloader up to date.
  • Pi 3B: set the OTP bit once. The 3B+ does not need it.
  • All models: if an SD card with an operating system is inserted, the Pi boots from it. If you want to keep it in the Pi as a rescue system, change the boot order.

Pi 5 on a 3 A power supply: according to the documentation, the Pi 5 then blocks booting from USB. The clean fix is the 27 W power supply. Alternatively, this line in config.txt lifts the lock:

usb_max_current_enable=1

On a running system the file is /boot/firmware/config.txt. If you add the line before moving your system, it is copied to the SSD. On a freshly written SSD, open the bootfs partition on your computer and add the line at the end of config.txt. The line also lifts the 600 mA limit. If the SSD then draws more current than the power supply can deliver, you risk undervoltage and crashes. The Pi 500 has the same 600 mA limit, but the documentation describes the boot lock only for the Pi 5. If a Pi 500 does not boot from USB, the same fixes apply; more are in the Pi 5 section of the USB boot guide.

Fresh install with Raspberry Pi Imager

You write a USB SSD or an SSD on an adapter on your computer, just like an SD card:

  1. Connect the SSD to your computer.
  2. In Raspberry Pi Imager, choose your Pi model, Raspberry Pi OS and the SSD as storage.
  3. Set hostname, user, Wi-Fi and SSH in the customisation settings.
  4. Write the image. Imager erases the SSD completely.

An NVMe SSD on the HAT is easiest to write directly on the Pi 5: boot it from an SD card with the desktop and choose the NVMe SSD as the target in Imager. Without a desktop, fit the SSD into an NVMe USB enclosure temporarily and write it on your computer. The individual steps are in the Imager section of the USB boot guide.

Move your system instead of reinstalling

Raspberry Pi OS with desktop comes with SD Card Copier preinstalled (package piclone). This is how you copy the running system to a USB or NVMe SSD:

  1. Boot the Pi from the SD card and connect the SSD.
  2. Open SD Card Copier from the Accessories menu.
  3. Choose the SD card under “Copy From Device” and the SSD under “Copy To Device”. Everything on the SSD will be erased.
  4. If the SD card is to stay in the Pi afterwards, tick New Partition UUIDs. Otherwise both drives share the same partition IDs (PARTUUID), which the Pi uses to find its partitions at boot, and it may end up mounting partitions from the wrong drive.
  5. Click Start, wait until the copy has finished and shut down the Pi.

In the terminal and on Raspberry Pi OS Lite, rpi-clone does the job, a tool from a third-party developer. Our guide clone a Raspberry Pi SD card to NVMe covers both methods in detail.

Boot and check

Plug the SSD into a blue USB 3.0 port (on the Pi 3 any USB port; an NVMe SSD already sits on the HAT), remove the SD card and power on the Pi. This command shows whether it runs from the SSD:

findmnt -n -o SOURCE /

/dev/sda2 stands for an SSD on USB, /dev/nvme0n1p2 for NVMe and /dev/mmcblk0p2 for the SD card. If it still shows the SD card, the card is inserted and takes priority: remove it or change the boot order. If the Pi does not boot at all, see the section “It still won’t boot” in our USB boot guide.

Conclusion

On the Pi 4, Pi 400 and Pi 500, use a ready-made USB SSD or a SATA SSD on an adapter that you have tested on the SD card system first. On the Pi 5, an NVMe SSD on the M.2 HAT+ is the fastest option. Hard drives and multiple drives belong on a hub with its own power supply.

Questions or problems are welcome in the comments.

Frequently asked questions about booting the Raspberry Pi from SSD

Which SSD is best for the Raspberry Pi 4?

A USB SSD in one of the blue USB 3.0 ports, either bought ready-made or as a 2.5-inch SATA SSD on a USB-SATA adapter. Test an adapter on a Pi running from its SD card first, because some fail under Linux in UAS mode. An NVMe SSD only works on the Pi 4 in a USB enclosure, as it has no PCIe connector.

Does a 2280 NVMe SSD fit the official M.2 HAT+?

No. The M.2 HAT+ takes SSDs in the 2230 and 2242 formats, the M.2 HAT+ Compact only 2230. A 2280 SSD needs a board from another manufacturer. If that board does not follow the HAT+ specification, you also need dtparam=pciex1 in config.txt and PCIE_PROBE=1 in the bootloader configuration.

Can I use an M.2 SATA SSD on the Raspberry Pi 5?

Not on the M.2 HAT+, which is meant for NVMe drives and other PCIe devices. In a USB enclosure that explicitly supports M.2 SATA, it works like any other USB SSD.

Does the Raspberry Pi supply enough power for an SSD or hard drive?

The Pi 4 supplies 1.2 A to all USB devices combined, the Pi 5 1.6 A on the 27 W power supply and only 600 mA on a 3 A supply. How much your SSD needs is stated in its datasheet. According to Raspberry Pi, hard drives and multiple drives belong on a USB hub with its own power supply.

Do I have to reinstall the system when switching from SD card to SSD?

No. SD Card Copier, which comes preinstalled with Raspberry Pi OS with desktop, or rpi-clone copies your running system to the SSD. You only need a fresh install with Raspberry Pi Imager if you want to start from scratch.

Is an SSD worth it on the Raspberry Pi 3?

For durability yes, for speed no: the Pi 3 only has USB 2.0, so an SSD is barely faster than a good microSD card there. The Pi 3B+ boots from USB out of the box, the Pi 3B needs the OTP bit set once.

Further reading

Similar Posts