In my experience it's: battery goes bad after 2-3 years and then you replace the laptop after 5 years because you are tired of using your laptop as a desktop computer because it shuts down as soon as you unplug it.
Sure after 2-3 years you still have some charge, but it's more like 1 hour when browsing the Internet and not the 6-7 hours that it had originally.
I might just be buying shitty laptops though. Do your phone batteries also last 5 years?