>Mac laptops may be eligible for an extended battery-only repair period for up to 10 years from when the product was last distributed for sale, subject to parts availability.
Probably makes sense, if you're organized enough, to get a battery swap while it's still in coverage if you'll use. My 2015 MacBook had a battery that got swollen a few years ago. Got it replaced and continue to use it as basically a browser and it's perfectly usable.
https://support.apple.com/en-us/102772
> Obsolete: ... MacBook Pro (Retina, 13-inch, Early 2015), MacBook Pro (Retina, 15-inch, Mid 2015)...