WASHINGTON (AP) - U.S. home prices rose at a solid pace in July, as would-be buyers competed for a diminished supply of available housing.

WASHINGTON (AP) U.S. home prices rose at a solid pace in July, as would-be buyers competed for a diminished supply of available housing.

The Standard & Poor's/Case-Shiller 20-city home price index climbed 5 percent in July from a year earlier. That's up from a 4.9 percent annual pace in June.

Home prices rose in all 20 cities over the past 12 months. San Francisco posted the biggest gain of 10.4 percent, followed by Denver with 10.3 percent.

Steady job growth and an economic recovery in its seventh year have encouraged more Americans to buy homes. That lifted sales to an eight-year high in July. Yet those buyers have bid up prices in many areas because the number of homes for sale remains below levels that are typical in a balanced market.

The Case-Shiller index covers roughly half of U.S. homes. The index measures prices compared with those in January 2000 and creates a three-month moving average. The July figures are the latest available.

Consistent price gains can make homeowners feel wealthier and more likely to spend, providing a boost to the economy. Higher home values also reduce the number of Americans who owe more on their mortgages than their homes are worth, a condition known as being "under water."

Still, housing faces several challenges in the coming months. Prices are rising at more than double the rate of wages, which have increased just 2.2 percent in the past 12 months. That is likely pricing many would-be buyers out of the market.

And while mortgage rates are still very low by historical standards, they could be headed up soon. Federal Reserve Chair Janet Yellen has indicated that the Fed may raise short-term rates for the first time in nine years before the end of the year. That would eventually push up mortgage rates.

Those trends may already be weighing on sales of existing homes. They slid nearly 5 percent in August from July's eight-year high to the lowest level since April, the National Association of Realtors said last week.

And fewer Americans signed contracts to buy homes in August. That suggests sales may slip further in the coming months. A signed contract typically precedes a completed sale by one or two months. Still, existing home sales are 6.2 percent higher than a year ago.