Home sales — and prices — reached a new high in the Twin Cities area last month, but the dearth of listings continued and may soon put a brake on deals.

During June, there were 7,430 closings, 2.2 percent more than last year and a record high, the Minneapolis Area Association of Realtors reported Tuesday. The median price of those closings was $259,000, a 7 percent increase and another new high.

“The numbers confirm what agents already know about this market,” said Cotty Lowry, president of the Minneapolis Area Association of Realtors and a sales agent with Keller Williams in Minneapolis. “We are still very thirsty for listings.

So far this year, sales are on pace to beat last year by fewer than 100 closings. But with new listings falling and pending sales flat, there’s a good chance that total sales this year will fall below 2016.

During June, there were 6,350 pending sales, just 15 more than last year. Pending sales have been flat for the past couple months, suggesting that low inventory will put a lid on sale closings in the coming months.

Sales are being driven by a combination of factors, including near-record low mortgage rates, a thriving economy and an increase in new households.

At the same time, however, homebuilders are failing to keep pace with demand, particularly for new starter housing.

The average 30-year fixed mortgage rate has been hovering around 4 percent. The long-term average for such rates is about 8 percent.

Though it’s been an unbeatable market for sellers, it’s been one of the worst for buyers.

Last month, there were just 8,683 homes that came into the market, slightly fewer than last year. And with deals happening faster than people are putting homes on the market, there were only 12,464 listings in the metro area at the end of the month, a 16.5 percent decline.

The listing shortage is particularly acute in the inner-ring suburbs where first-time buyers like Rachel Herbison and Sam Koehn started house shopping at the beginning of June.

The couple had already heard tales of bidding wars and multiple offers, so were bracing for the worst.

Their wish list looked like that of a lot of millennial home buyers. They wanted a house with at least 1,100 square feet, a spacious backyard and a two-car garage. They were even willing to buy a fixer-upper, preferably with a kitchen that could be remodeled to create an open floor plan.

Their first shopping excursion took them to six houses, including one that checked every box. Problem was, another buyer had already made an offer on it. After some coaching from their agent, they made a competing offer and got the house and will close at the end of this week.

“We had heard so many horror stories about the market,” Herbison said. “To say the least, our experience was surreal.”

Their agent, Man Huynh, president-elect for the St. Paul Area Association of Realtors, said the situation demonstrates that a buyer’s persistence can pay off if they have a negotiation plan.

On average, houses that sold in June were on the market just 47 days, or 16 percent faster than a year ago. At the current sales pace, there are only enough houses on the market to last 2½ months, the lowest June reading since 2003. Generally, five to six months of supply is considered a balanced market where neither side has a clear advantage.

“That means sellers who list well-presented, well-priced homes are being rewarded,” Lowry said. “And they’re finding the move-up market to be less competitive.”