The average lifespan of a pet goldfish ranges from 5 to 10 years. However, with proper care and a suitable environment, they can sometimes live for up to 15 years or more. It's important to provide them with a clean tank, appropriate food, and regular maintenance to help ensure a longer and healthier life for your goldfish.