NEW YORK – Stocks snapped a six-week decline Friday as European leaders moved closer to a compromise on a financial rescue for Greece and an index of leading U.S. economic indicators advanced more than forecast.

The Standard & Poor’s 500 Index advanced 0.3 percent to 1,271.50, preventing the longest weekly slump since March 2001. The Dow Jones industrial average increased 42.84 points, or 0.4 percent, to 12,004.36.

“This may be an excellent entry point for stock investors,” said James Paulsen, the chief investment strategist at Minneapolis-based Wells Capital Management. “There are expectations that an agreement on Greece’s bailout may be reached. If we can get rid of the fears over Europe, it all comes down to — do we believe the economy will reaccelerate in the second half of this year? If that’s the case, stocks have room to rally.”

Global stocks rose as Chancellor Angela Merkel retreated from German demands that bondholders be forced to shoulder a “substantial” share of a Greek rescue, saying she’ll work with the European Central Bank to avoid disrupting markets.

Stocks extended gains after data showed that the index of U.S. leading indicators rebounded in May after declining for the first time in almost a year, a sign economic growth may pick up by the end of 2011. The Conference Board’s gauge of the outlook for the next three to six months rose 0.8 percent after a revised 0.4 percent decline in April, the New York-based group said. Economists had forecast a 0.3 percent gain, according to the median estimate in a Bloomberg News survey.

“The economy is not as good as hoped, not as bad as feared,” said Stephen Wood, the New York-based chief market strategist for Russell Investments.