Long Island home prices climbed last month, but the pace of sales slowed in Nassau County and hardly budged in Suffolk County as the supply of homes dwindled.

The median closed sale price in Nassau County was $480,000 in July, a 5.5 percent increase from a year earlier, the Multiple Listing Service of Long Island reported Wednesday. In Suffolk County, the median price rose by 2.1 percent year-over-year, to $345,000.

The number of homes changing hands fell by 7.1 percent annually in Nassau, with 1,208 closed transactions. Suffolk County home sales inched up 0.6 percent, to 1,478.

“The market has gotten better, we’ve gotten rid of a lot of the foreclosures and short sales,” said Gary Baumann, an associate broker with Douglas Elliman in Huntington and Port Washington.

However, a shortage of listed homes — especially desirable, properly priced homes — is holding back the pace of sales, he said.

The number of homes listings dropped by 18 percent year-over-year in each county, to 15,094 Islandwide.

advertisement | advertise on newsday

Some sellers try to test the market by listing their homes at too-high prices, Baumann said.

“When the gap between what a seller thinks their house is worth and what a buyer is willing to pay goes above 5 percent, it’s very hard to bring the buyer and seller together, and that’s what I see happening on an awful lot of houses,” Baumann said. “It definitely puts a damper on the number of sales.”

In some cases, homeowners are choosing to remodel homes rather than trading up, since rising prices have put trade-up homes out of reach, said Joe Moshé, broker-owner of Plainview-based Charles Rutenberg Realty.

“Instead of moving, they’re upgrading,” Moshé said. “People are comfortable where they’re living.”

And as more buyers get priced out of Nassau, they have grown willing to commute from Suffolk to jobs in New York City or on the Island.

“The move is to Suffolk,” Moshé said. “For a lot of people, you get greater value.”