Net income rose to $6.50 billion, or $1.60 a share, in the second quarter ended June 30 from $4.96 billion, or $1.21 a share, a year earlier.
The year-earlier quarter included the vast majority of the losses of more than $6.2 billion on derivatives positions that were so large that hedge funds had referred to the trader handling them as the "London Whale."
Provision for credit losses fell 78 percent to $47 million.
Analysts on average had expected earnings of $1.44 a share, according to Thomson Reuters I/B/E/S. It wasn't immediately clear if the figures were comparable.
JPMorgan Chase (JPM), shares of which were down marginally in premarket trading, said revenue from fixed income and equities rose 18 percent in the quarter compared with a year earlier.
The corporate and private equity division, which a year ago lost $1.78 billion after-tax because of the London Whale debacle, lost $522 million in the latest quarter.
Mortgage banking income, which comes from making home loans and servicing existing mortgages, fell 14 percent to $1.1 billion as a refinancing wave subsided and interest rates rose.
JPMorgan is the second largest U.S. mortgage lender after Wells Fargo (WFC) with an 11 percent market share. Wells Fargo reports results later Friday.
JPMorgan shares, which were trading at $54.85 before the bell, had risen 25 percent this year up to Thursday's close, helped by growing confidence that the U.S. economy is on the road to a solid recovery.
However, the stock has been volatile in recent weeks because of concern that higher interest rates will erode the value of bank assets before they generate new revenue from lending.
The results are the first the bank has released since Chairman and Chief Executive Jamie Dimon overwhelmingly won a shareholder referendum in May on whether he should hold both posts.