The short answer
For an operating system and everyday applications, an SSD is usually the better experience because it has much lower access latency and no mechanical seek time.
When HDD still makes sense
Hard drives can still be useful when you need a lot of storage at low cost, especially for backups, archives and media that do not need SSD-like responsiveness.
Check the interface
Before buying, confirm whether your device accepts 2.5-inch SATA, M.2 SATA, M.2 NVMe or another format. M.2 describes a physical form factor and does not automatically mean NVMe.
Do not confuse storage with backup
A larger or faster drive is not a backup by itself. Important files should exist in more than one independent location.