The government's chief economic barometer rose a strong 0.8 percent in June, indicating more growth ahead -- but also the possibility of higher prices, the Commerce Department said yesterday.

The index of leading economic indicators drew strength from the stock market and from rising materials costs in June to post its best gain since March, the government said. May's increase was revised downward to 0.5 percent from the earlier 0.7 percent estimate, while April stayed unchanged at a 0.2 percent rise.

The government released two other reports that contained both good and disturbing news about the economy.

It said the sales rate for new homes perked up by 3.5 percent in June, but that new home prices had soared to an average of $139,700. And it said import prices rose 4 percent from April to June -- triple the overall inflation rate for the quarter.

The index of leading economic indicators tracks 11 parts of the economy to give an idea of how the country will fare over the next nine months. Lately, the news has been consistently good, with the index dropping only three times since January 1985.

More than half of June's 0.8 percent gain came because of higher prices for "sensitive materials" -- 28 types of products, from cattle hides and lumber to scrap iron and cotton -- for which prices swing according to demand.

Those prices went up 1.56 percent in June, so the government figures demand must be high and the economy on a roll.

The stock market provided most of the rest of June's increase. Standard & Poor's 500-stock index rose 4.2 percent during the month. Minor help came from a modest rise in new orders for consumer goods and materials and an increase in the number of building permits issued.

Four factors were minor drags on the index: a tick upward in the number of new unemployment claims, a drop in contracts and orders for plants and equipment, improved delivery of products by vendors and a small shrinkage of the money supply.

One other factor, the length of the average week worked by production workers, was unchanged. Information was unavailable on changes in inventories and in credit.

Irwin Kellner, chief economist for Manufacturers Hanover Corp. in New York, said he disliked the price increase for sensitive materials.

"It tells me that, before long, we'll be looking another recession square in the face," he said. Kellner added that he believes the economy will keep growing this year, but a fall could be coming in 1988.

Fellow economist Allen Sinai thought Kellner was reading too much into the report.

"The index is giving a very strong signal that the economy is on a good, expansionary path for at least the next six to nine months," said Sinai, of Shearson Lehman Bros. Inc. in New York. "It's hard to find any sign of trouble."

Roger Brinner of Data Resources Inc. agreed. "The indicators are signaling good strength for the economy ahead," said Brinner.

In the housing report, the departments of Commerce and of Housing and Urban Development estimated new single-family homes sold at a seasonally adjusted annual rate of 658,000. That number indicates how many homes would be sold if every month were like June and seasonal factors were taken into account.

The report also figured the median price for a new home in America -- the price at which half of all homes cost more, the rest less -- reached $110,000 in June. Equally, the government revised May's median price to $106,000, marking the first time that a price of more than $100,000 held up after revisions.

The average price for a new home in June stood at $139,700, up from May's average of $128,600, the government said.

The import report showed how important energy costs are to the total imports package. While import prices rose 4 percent from April through June, fuel costs were up 10.3 percent. Exclude fuel and the imports would have shown only a 2.6 percent rise, the government said.

Prices for U.S. exports rose 2.8 percent during the same period.