The short answer
Quick answer: A hard disk drive (HDD) stores data on spinning magnetic platters and must physically move a read head to the right spot, which takes several milliseconds per access. A solid-state drive (SSD) stores data as electrical charge in flash memory cells and has no moving parts, so it can reach any piece of data in a fraction of a millisecond. The difference is largest for random access, which is exactly what booting, launching apps and running databases need.
| HDD | SATA SSD | NVMe SSD | |
|---|---|---|---|
| Storage medium | Magnetic platters | NAND flash | NAND flash |
| Moving parts | Yes | No | No |
| Random access time | Several milliseconds | Around 0.1 ms | Tens of microseconds |
| Random operations per second | Roughly 100 to 200 | Tens of thousands | Hundreds of thousands or more |
| Sequential speed | Roughly 100 to 250 MB/s | Up to about 550 MB/s | Several GB/s |
| Cost per GB | Lowest | Higher | Higher |
| Shock resistance | Poor | Good | Good |
Figures are typical ranges and vary by model.
How a hard drive works
Inside an HDD, one or more rigid platters coated with magnetic material spin at a constant speed, commonly 5,400 or 7,200 revolutions per minute. A tiny head on the end of an arm floats nanometres above the surface, reading and writing magnetic patterns.
To read a block, two mechanical things must happen:
- Seek. The arm swings to the correct track. This takes several milliseconds on average.
- Rotation. The drive waits for the right part of the platter to spin under the head. At 7,200 RPM a full turn takes about 8.3 ms, so the average wait is about 4 ms.
Add them up and a random read costs around 10 ms. That limits a hard drive to roughly a hundred or two random operations per second, no matter how fast the computer is.
Sequential reads are a different story. Once the head is in place, data streams past continuously, so large files read at a respectable speed. Hard drives are slow at jumping around, not at reading in a straight line.
How an SSD works
An SSD stores bits in NAND flash cells. Each cell is a transistor with an insulated region that can trap electrons. The amount of trapped charge represents the stored value, and it stays there without power.
Cells differ in how many bits they hold:
| Cell type | Bits per cell | Trade-off |
|---|---|---|
| SLC | 1 | Fastest, most durable, most expensive |
| MLC | 2 | |
| TLC | 3 | Common in consumer drives |
| QLC | 4 | Cheapest and densest, slower writes, least durable |
Reading a cell is purely electrical. There is no arm and no spin, so every location is equally quick to reach. A random read takes tens to hundreds of microseconds, which is why the latency numbers every programmer should know put SSDs so far ahead of disks.
The awkward rules of flash
Flash has constraints that the drive's built-in controller has to hide:
- You cannot overwrite in place. A cell must be erased before it is written again.
- Erasing works on large blocks. Data is written in small pages but erased in much bigger blocks.
- Cells wear out. Each one tolerates only a limited number of erase cycles.
To cope, the controller runs a flash translation layer that maps the block numbers your computer asks for onto physical locations, and it does three clever things:
- Out-of-place writes. An update is written to a fresh page, and the old page is marked stale.
- Garbage collection. In the background, the drive copies still-valid pages out of mostly stale blocks and erases those blocks for reuse.
- Wear levelling. Writes are spread evenly so no group of cells dies early.
The TRIM command helps: when you delete a file, the operating system tells the drive which blocks are no longer needed, so garbage collection does not waste effort preserving them. More on that in how file systems work.
SATA vs NVMe
Early SSDs used SATA, an interface designed for hard drives. Its protocol handles one queue of 32 commands, and its speed tops out around 550 MB/s. That was a ceiling imposed by the cable and protocol, not by flash.
NVMe was designed for flash. It connects over PCIe lanes directly to the CPU and supports thousands of parallel queues. That removes the bottleneck, letting modern drives reach several gigabytes per second and very high random performance.
Why this changed software
Fast random access reshaped how software is built:
- Boot and app launch involve thousands of small scattered reads. This is where the upgrade from HDD to SSD is most visible.
- Swapping became a stutter instead of a freeze. See why your computer slows down when RAM fills up.
- Databases were long designed around avoiding disk seeks. With SSDs, different trade-offs make sense; see B-trees vs LSM trees.
- Defragmentation is pointless on SSDs, since position does not affect speed.
When a hard drive still makes sense
Hard drives remain the cheapest way to store a lot of data. They are still a sound choice for:
- Backups and archives.
- Large media libraries.
- Bulk storage in data centres, where cost per terabyte matters most.
Both types fail eventually, in different ways. Hard drives suffer mechanical wear and are vulnerable to shocks. SSDs wear out with writes and can fail suddenly. Neither replaces a backup.
Frequently asked questions
Do SSDs wear out?
Yes, each cell survives a limited number of writes. In practice, wear levelling means a typical consumer drive lasts many years of normal use. Manufacturers state endurance as "terabytes written".
Is NVMe noticeably faster than SATA for everyday use?
For large file copies and heavy workloads, clearly. For everyday tasks such as browsing and office work, the jump from HDD to any SSD is far bigger than the jump from SATA to NVMe.
Can data be recovered from an SSD?
It is harder than with a hard drive. Because of TRIM and garbage collection, deleted data is often physically erased soon after deletion.
Why do SSDs slow down when nearly full?
With little free space, the controller has fewer empty blocks and must do more garbage collection during writes. Keeping some space free helps.
Conclusion
The speed difference comes down to physics: a hard drive must move metal, and an SSD only moves electrons. That turns a ten-millisecond wait into a fraction of a millisecond, and it matters most for the scattered small reads that dominate real workloads. Use SSDs for anything you run and hard drives for anything you merely keep.
Related articles
- How File Systems Store Your Files on Disk
- Why Do We Need Both RAM and Storage?
- Why Your Computer Slows Down When RAM Fills Up
- B-Trees vs LSM Trees: Why Databases Store Data Differently
