Or better yet, have a backup & don't worry about paying. The time to avoid having to deal with ransomware is taking steps BEFORE you get it. After you get infected, there is a extremely slim chance, if any, of recovering your data unless you pay up.

Ransomware-as-a-service is exploding: Be ready to pay - TechRepublic

It starts with a fast click on a link in a harmless-looking email. Then your PC slows to a crawl. A message suddenly pops up and takes over your screen. "Your files and hard drive have been locked by strong encryption. Pay us a fee in 12 hours, or we will delete everything." Then a bright red clock begins counting down. No antivirus will save your machine. Pay the fee or lose everything.
Windows comes with it's own free tool to make a system image. This is included in Win 7 & 8 as well as 10. Make one on a regular basis & keep it on an external drive that is not hooked up to the PC/Laptop all the time.

System Image - Create in Windows 10 - Windows 10 Forums

A system image is an exact copy of all system disks which can be used to restore your PC to the state it was in at the time the image was made. By default, a system image only includes the drives that Windows requires to run, including Windows 10 itself, your system settings, programs, and files. You may also include any other drive in the image if you wish. When you restore your computer from a system image it is a complete restoration, you cannot choose individual items to restore and all of your current programs, system settings, and files are replaced with the contents of the system image.