There is nothing glamorous about paying for a new roof, but there are few other things on which homeowners should place a higher priority than protecting the investment that is literally above their heads.

The cost of replacing a roof is as variable as homes themselves. The size or pitch of the roof, the condition of existing decking, the materials used, the number of layers, local building code requirements and many other aspects can affect the bottom-line cost. According to Home Advisor, the average national cost for replacing a roof in 2016 was $7,020, with a cost of $2,000 at the low and as much as $30,000 at the high end.