The average cost of replacing a heater or heat exchanger typically ranges from $1,000 to $3,500. This cost can vary significantly based on several factors, including the type of heater or heat exchanger, the brand, the complexity of the installation, and the region where the replacement is taking place. 
For a standard residential furnace, the cost might be on the lower end, around $1,000 to $2,500, including both parts and labor. High-efficiency models or those with advanced features can push the cost to the higher end of the spectrum, around $3,000 to $3,500 or more. 
If the replacement involves a heat exchanger within a furnace, the cost can be slightly different. A heat exchanger alone might cost between $500 and $1,500, but when you factor in labor, the total cost can range from $1,000 to $2,000. 
Labor costs are a significant part of the total expense, often accounting for $500 to $1,500 of the total cost, depending on the complexity of the installation and the rates in your area. 
Additional costs may arise if there are complications, such as the need for ductwork modifications, electrical upgrades, or permits. 
It's important to get multiple quotes from licensed HVAC professionals to ensure a fair price and quality service. Regular maintenance and timely repairs can extend the life of your heating system, potentially delaying the need for a full replacement.