All desktop and laptop computers use a special battery called a Complementary Metal Oxide Semiconductor (CMOS) battery which stores information about your computer, such as the date and time, when the machine is powered off. Normally the Laptop battery re-charges itself whenever the computer is turned on but if it stops working or becomes damaged you will need to replace it manually.
Read more here:
How to Replace PC CMOS Battery