Orders for machinery rose 2.9 percent. Iron and steel mills had a 1.7 percent increase in demand, while orders for computers and electronic products were up 2.9 percent.
Excluding military hardware, factory orders rose 1 percent in June from May.
Over the past year, factory orders were up 2.5 percent.
The improved outlook for business spending has helped drive growth. The economy grew at an annual rate of 4 percent in the April-June quarter, after slipping 2.1 percent during the first three months of the year when brutal winter weather closed some assembly lines.
Manufacturing has rebounded as the weather improved.
The Institute for Supply Management, a trade group of purchasing managers, reported Friday that its manufacturing index rose to 57.1, up from 55.3 in June. A reading above 50 signals that manufacturing is growing.
"The growth in manufacturing activity and capital spending is likely to continue next month, as indicated by a moderate increase in ISM new orders level in July," said Maninder Sibia, economist at Contingent Macro Advisors.
The increased demand has fueled hiring. The Labor Department said Friday that employers added more than 200,000 jobs in July for the sixth straight month. Factories accounted for 28,000 new jobs in July. Over the past year, manufacturers have added 178,000 jobs, best 12-month stretch of hiring since November 2012.