Historically, windows requires 15% to defragment a (magnetic spinning) hard drive. (As bentenmusume-san says, whether that is automatic depends on settings).
Solid state drives (SSDs) with modern versions of Windows essentially manage fragmentation automatically, but you should leave 25% free space for best performance.
But, very modern SSD usually have hidden capacity specifically to leave room for defragmenation needs and as replacements for failing sectors, so... how much space you actually need to leave depends on how much hidden capacity there is.
The benchmarks are clear: Solid-state drives slow down as you fill them up. Fill your solid-state drive to near-capacity and its write performance will decrease dramatically. The reason why lies in the way SSDs and NAND Flash storage work.
As dear madchachi recommended, fragmentation can be an alternative, though it mostly arranges the programs in HDD partitions for a better function and speeding up the programs execution, nonetheless it collects and arranges the outspread empty spaces of every partition in one place that can increase the HDD operational empty space.
The second alternative is cleaning up HDD from unnecessary or junk files and programs. Windows itself has such the facility but it is not a developed and comprehensive one. There are some cleaning up software that can help users to remove unnecessary occupant files and also wash registry from unnecessary keys and thus polish it ! But you should be careful about such the software and choose the most reliable one, because some of them can remove a program or file that you don't want to be deleted, and some of them even do this automatically every week or month!