Wells Fargo led bank stocks higher Friday as most of the biggest U.S. lenders announced plans to boost stock repurchases and quarterly dividends by billions of dollars after passing the Federal Reserve's annual stress test.

San Francisco-based Wells Fargo was the "big winner" from this year's annual regulatory ritual because investors had feared the scandal-ridden company would get dinged on the qualitative portion of the exam, according to a research note from Macquarie analyst David Konrad entitled "WFC wins the day." Earlier this year, the Fed ordered Wells Fargo to cap its assets until it could improve its operational controls amid revelations of sales practice abuses.

Instead, Wells Fargo passed and won permission to buy back $24.5 billion in shares, more than double last year's and clobbering Konrad's $15.5 billion estimate.

Wells Fargo surged almost 6 percent at 11:04 a.m. in New York trading. Meanwhile shares of Citigroup rose 2.1 percent, while J.P. Morgan Chase and Bank of America rose less than 1.5 percent.

CItigroup said it would hike its quarterly dividend 13 cents, to 45 cents a share, and buy back $17.6 billion of stock over the next year after passing the Fed's annual stress test.

J.P. Morgan Chase announced it would raise its quarterly dividend to 80 cents a share from 56 cents, and buy back up to $20.7 billion in stock.

The Fed gave 34 of the biggest banks the go-ahead to pay dividends and buy back stock after the second part of annual stress tests, it announced Thursday. For firms that disclosed their plan approvals, the total capital return rose 22 percent to $172 billion, according to JMP Securities analyst Devin Ryan.

"We characterize the overall outcome for the group as a modest positive, on balance representing another year of forward progress," Ryan said in a Thursday research note.

Only the U.S. unit of Deutsche Bank had an outright failure in the exam, limiting the German lender's ability to pull in dividend payments from its American business. Goldman Sachs and Morgan Stanley received conditional approval but will only be paying out roughly what they did last year. Morgan Stanley said it would raise its quarterly dividend to 30 cents a share from 25 cents and buy back $4.7 billion of stock, consistent with the $6.8 billion in capital it returned over the last year.

Goldman said it would raise its dividend by 5 cents to 85 cents a share in the second quarter of 2019 and buy back $5 billion of stock, not going over $6.3 billion. Both firms disappointed expectations for capital return, and their shares rose less than 0.5 percent.

It is the second year of massive capital return announcements. Last year, J.P. Morgan announced its biggest share buyback since the financial crisis and Citigroup doubled its dividend.