A main water line lasts 40 to 70+ years on average. The water line’s lifespan depends on the material it’s made of, your local climate, and the soil conditions.
Most copper piping lasts 50 to 100+ years.
PEX water lines lasts up to 30 to 50 years.
PVC pipes can last 100+ years but do not perform well in extreme temperatures.