NEW YORK — Emboldened by soaring stock prices and record-low borrowing costs, stock investors are taking out loans against their portfolios at the fastest pace since before the Great Recession hit.

So-called margin debt hit $379.5 billion in March, the highest level since July 2007 when such debt hit an all-time record of $381.4 billion, according to the most recent data available compiled by the New York Stock Exchange.

The trend signals that investors are more comfortable with stocks and are more willing to use borrowed money to buy more securities in hopes of garnering fatter returns in a hot market that has pushed the Dow Jones industrials up more than 15% in 2013.

But there's also a dark side: The use of borrowed money also could be signaling that risk-taking is becoming extreme and that investor enthusiasm is becoming too bullish, which could set those investors and the market up for disappointment if stocks turn south.

In short, rising margin debt could also be a sign of growing investor complacency.

"Margin debt is now (near) record levels," says Bruce Bittles, chief investment strategist at R.W. Baird. "When investors are willing to borrow lots of money to buy stocks, that is a sign of real optimism."

Bittles adds, "At important points in the stock market, investor sentiment typically is the best guide."

But he says margin debt is just one aspect of the overall sentiment picture. He notes that the latest weekly poll of its members by the American Association of Individual Investors found more bears than bulls, a sign that sentiment is not yet at irrationally exuberant levels.

Still, current margin debt levels are 28% higher than they were in March 2012, and nearly 36% higher than at the market peak in March 2000.

The past two times margin debt peaked in 2007 and 2000 it was also a sign of a stock market top, data show.

"Soaring margin debt certainly supports the charge (from bears) that the Fed is once again inflating asset bubbles," Edward Yardeni of Yardeni Research told clients in a research note.

But Yardeni also says optimism is not at extreme levels yet, citing still-reasonable stock valuations relative to earnings despite the big run-up. But he warns that "could change quickly in a debt-financed melt-up of stock prices."

One major concern is that if stock prices suddenly tank, many investors who have been buying stocks with borrowed money will have to sell shares to raise cash to meet margin requirements. And those forced sales could exacerbate any market correction.

Unlike mortgage debt, where one's home is collateral, the collateral for margin loans is securities, such as stocks. Investors who borrow from their portfolio balances, however, don't use the money only to buy other securities. They can use the cash to fund any purchase. The interest they pay on the loan is tax deductible, just as it is for a home loan.