Estimate the cost of PC upgrades.
The upgrade-or-replace decision turns on two ratios. Upgrade cost as a share of a new machine is the blunt test — once parts approach two thirds of a replacement, the replacement wins on warranty alone. Cost per extra year of service is the finer one, because a modest memory and storage upgrade that buys three more years is nearly always the cheapest computing you will ever purchase.
Upgrade total
Total = memory + storage + graphics card cost
Decision ratios
Cost per extra year = total / extra years gained; share of new = total / new machine price x 100
On any machine still using a mechanical hard drive, an SSD is transformative and usually the cheapest option. After that, adding memory helps if you routinely run out; a graphics card only helps graphics workloads.
Soldered memory and storage. Many thin laptops allow no upgrades at all, which forces the replacement decision regardless of the arithmetic.