Hedge funds are borrowing more to buy equities just as loans by New York Stock Exchange brokers reach the highest in four years, signs of increasing confidence after professional investors trailed the market since 2008.

Leverage among managers who speculate on rising and falling shares climbed to the highest level to start any year since at least 2004, according to data compiled by Morgan Stanley. Margin debt at NYSE firms rose in November to the most since February 2008, data from NYSE Euronext show.

The rising use of borrowed money shows that everyone from the biggest firms to individuals is willing to take more risks after missing the rewards of the bull market that began in 2009. While leverage means bigger losses should stocks decline, investors are betting that record earnings and valuations 9.8 percent below the six-decade average will help push the Standard & Poor’s 500 Index toward the record it set in October 2007.

“The first step of increasing risk is just going long, the second part of that is levering up in order to go longer,” James Dunigan, who helps oversee $112 billion as chief investment officer in Philadelphia for PNC Wealth Management, said in a Jan. 8 telephone interview. “Leverage increasing in the hedge-fund area suggests they’re now getting on board.”

The S&P 500 rose 0.4 percent to 1,472.05 last week on better-than-projected reports from Alcoa Inc. to Mosaic Co. The index is about 6 percent away from the all-time high reached in October 2007 and has already gained 3.2 percent in 2013, led by Celgene Corp. It fell less than 0.1 percent to 1,471.55 at 9:37 a.m. New York time today.

Stock Rally

Gross leverage, a measure of hedge fund borrowing that shows how much their holdings exceed the cash invested by clients, was 153 percent in the week ended Jan. 4, up from an average of 152 percent in 2012 and 143 percent a year ago, according to data from New York-based Morgan Stanley. The level has averaged 143 percent since 2005, the data show.

Managers are borrowing more amid a 15 percent rally in the S&P 500 since June, a gain that was mostly missed by professional investors who speculated shares would fall, according to data from Hedge Fund Research Inc. and International Strategy & Investment Group.

Borrowing increased as President Barack Obama and Republican lawmakers reached an agreement averting more than $600 billion in automatic tax increases and spending cuts.

‘Pretty Optimistic’