(Bloomberg) -- U.S. homebuilders are riding a wave of optimism as record low mortgage rates drive demand for new homes.

A gauge of builder sentiment jumped to 78, a six-point gain from July that pushed it to the highest level since 1998, according to the National Association of Home Builders/Wells Fargo Market Index. The August number was better than the median analyst estimate of 74 and matched an all-time record in 35 years of the survey.

The index ended 2019 at a 20-year high but plunged when the coronavirus shut down the U.S. economy in March. Builders have bounced back since then, with the housing market an unexpected bright spot in an economy battered by the pandemic.

The demand for new housing, fueled by low borrowing costs, is boosting builders, particularly because inventory of existing homes is low.

An index that tracks the shares of builders has surged more than 140% since the stock market hit a low on March 23.

©2020 Bloomberg L.P.