The leaks, from Panama-based law firm Mossack Fonseca, showed Sigmundur Gunnlaugsson owned an offshore company with his wife but had not declared it when he entered parliament
He is accused of concealing millions of dollars’ worth of family assets.
Mr Gunnlaugsson says he sold his shares to his wife and denies any wrongdoing.
He is one of dozens of high-profileglobal figures mentioned in the 11.5 million leaked financial and legal records, which were first published on Sunday.
Pressure on Mr Gunnlaugsson to quit had been building since then, with thousands of people protesting outside the parliament building in the capital Reykjavik on Monday and opposition parties tabling a confidence motion.
Earlier on Tuesday, the prime minister asked President Olafur Ragnar Grimsson to dissolve parliament and call an early election.
But Mr Grimsson said he first wanted to consult leaders of the Independence Party, which has been in the ruling coalition with Mr Gunnlaugsson’s Progressive Party since 2013.
Gudlaugur Thor Thordarson, the chairman of the Independence Party, said the prime minister’s request had come as a “total surprise” and was not “the rational thing to do”.
Later, ahead of the confidence vote, Mr Gunnlaugsson announced he was stepping down.
The Progressive Party’s deputy leader, Agriculture Minister Sigurdur Ingi Johannsson, told reporters after a meeting that the party planned to name him as the new leader and propose that he become prime minister.
Despite the resignation, Katrín Jakobsdottir, head of the Left-Green Movement, told the Reuters news agency that opposition parties still wanted early elections.