The only thing that will protect you from lightning is unplugging your computer from the wall outlet. And don't forget to unplug the modem. It is connected to the computer, too.
Surge protectors are for surges in power. They will reduce incoming power surges to harmless voltage levels. They do not protect you from lightning.
If you want protection from brief blackouts as well as power surges, you need something called a UPS (uninterruptible power supply). This contains batteries that provide from five to about 30 minutes of power. This gives you enough time to save your document, close the file, quit the program and shut down the computer.
Different computers require different devices, so check your manual for its requirements.
Computer user groups/clubs are welcome to submit tips on technology for Tech Times. Items will be edited for space and clarity. Send e-mail to techtimessptimes.com, or write to Tech Times, P.O. Box 1121, St. Petersburg, FL 33731.