Factory activity in February shrank less than forecast as gains in new orders and production provided signs that the beleaguered industry could soon stabilize.

The Institute for Supply Management’s index climbed to 49.5, the highest since September, from 48.2 in January, a report from the Tempe, Az.-based group showed Tuesday. While the reading was just shy of 50, the dividing line between contraction and expansion, last month’s improvement corroborates other industry reports that suggest the manufacturing slump may be easing.

Factories have been plagued by a steady stream of headwinds since mid-2014, including soft overseas markets, a strengthening dollar, weakness in the capital-intensive oil industry and a buildup in inventories that reduced the need for additional production. As those hurdles start to fade, factories should also find a source of strength in domestic demand, which is being boosted by consumers with solid job gains and a nascent pickup in wage growth.

“It’s going to be a continued bumpy path in the near term for manufacturing,” though “ on the domestic side, the consumer appears to be in good shape,” Scott Brown, chief economist at Raymond James Financial Inc. in St. Petersburg, Fla., said before the report. “Consumers are a little bit nervous about the overall economy, but they’re generally feeling a lot better about their own personal finances, and as such, it bodes well for spending down the line, particularly in big-ticket items.”

The median forecast of 77 economists surveyed by Bloomberg called for 48.5. Estimates ranged from 47.2 to 51.

The new orders gauge last month was 51.5, matching the January reading as the highest since August. The production measure climbed to 52.8, a six-month high, from 50.2.

The employment index increased to 48.5 from 45.9, indicating factories trimmed staff at a slower pace. The February jobs report comes out on March 4.

Tuesday’s data showed shipments abroad continued to be pressured as the stronger dollar and soft global demand combine to make it harder for foreign markets to purchase U.S. goods. The export orders measure decreased to 46.5, the lowest in five months, from 47 in January. Exports have contracted in eight of the past nine months.

“You’re still seeing constraints coming from the rest of the world,” Brown said. “For U.S. exporters, it’s still going to be a problem.”

Last week’s second estimate of gross domestic product showed companies made less headway than originally thought in cutting back inventories in the fourth quarter, but the new year may be bringing some progress. Smaller stockpiles would boost the need for new production, helping offset the drag from trade.

“The ISM report shows that manufacturing activity is taking the brunt of the global energy imbalance and the adjustment to a strong dollar. The overall economy is being driven by solid job growth and accompanying income and consumption growth,” Meckstroth concluded.

“Unfortunately, consumers buy more services than goods and the goods they do buy are increasingly imported rather than domestically produced. In this modest GDP growth environment, businesses are cautious and less willing to invest in new equipment. Furthermore, the material industries within manufacturing are dealing with the emerging market slowdown and its deflationary consequences. We now expect manufacturing production to post only modest 1% growth in 2016—decelerating from 2% growth last year.”

Unsold Goods

The gauge of factory inventories improved to 45 in February, meaning stocks were being cut at a slower pace, from 43.5, while customer stockpiles declined to 47 from 51.5. This was the first reading lower than 50, meaning factory managers no longer believe their customers have too many goods on hand, since July.

The report also showed that while prices continue to fall, the pace of decline is starting to moderate. The prices-paid index improved to 38.5 from 33.5. The measure has been contracting since November 2014.

The ISM report adds to evidence that the pressure on manufacturing may be easing somewhat. Data published last week showed orders for capital equipment, a harbinger of business spending on machinery, computers and the like, jumped in January after plunging to a more than two-year low at the end of 2015.

A separate report from the Federal Reserve showed factory output climbed in January by the most in six months, boosted by production of consumer goods.