Linux is pretty amazing in that regard. It will boot just about anything and faster than Windows. If you own an old computer that refuses to work, get yourself a copy of a “live” Linux (google it), and revive your old computer for anything you want it to perform like holding photos, use it as a router, use it as a security camera, etc.
You might have to do a little research into booting from a CD/DVD or USB stick, but it is worth the trouble. Every computer is different in that way.
My laptop runs on Linux Lite, one of several open-source operating systems specially designed to work on old computers. The use of a Linux operating system is not a mere suggestion. There’s no way you’re going to revive an old laptop if you stick to Microsoft Windows or Apple OS because the machine would freeze instantly.
solar.lowtechmagazine.com/2020/12/how-and-why-i-stopped-buying-new-laptops.html