All computers have physical memory, or RAM, which loads the operating system and active programs. In some cases, RAM is soldered to the motherboard, while in others, it is installed using removable memory modules. Either way, the system memory is limited to the total RAM installed. Modern PCs typically have between 4 GB and 32 GB of RAM.
When you open an application, your computer loads the app and related files into RAM. If you open enough programs at one time, your computer will eventually run out of memory. Instead of producing an "out of memory" error or forcing programs to quit, your computer can "swap" physical memory into virtual memory.
Virtual memory is space on a storage device, such as an SSD or HDD, that serves as temporary system memory, similar to RAM. This "secondary memory" can expand a computer's memory beyond the physical memory limit. However, since storage devices are much slower than the RAM, data stored in virtual memory is often swapped back to RAM when accessed.
Swapping data between the primary memory takes time. Therefore, the more your computer uses virtual memory, the more it will slow down. One of the best ways to improve your computer's performance is to install additional RAM. With more free memory, your computer won't need to use virtual memory as often, resulting in fewer slowdowns and faster overall speed.