"To be a political leader... and to live as a committed Christian, to hold faithfully to the Bible's teaching, has felt impossible for me," he said.
Farron, 47, said he had felt "torn" between political and religious life after facing questioning over whether he agreed with his party's positive view of same-sex unions.
A father of four, Farron was elected leader of the Liberal Democrats in July 2015 after the party -- which had been in a coalition with the ruling Conservatives -- was nearly wiped out in the general election, losing 48 seats.
However, the party created one of the surprises in last week's snap election, increasing their number of MPs from nine to 12, after campaigning for a second referendum on the terms of Brexit.
But Farron's stance on gay rights grabbed headlines very early on the campaign and he was asked to clarify whether he thought being gay was a sin after a 2015 interview resurfaced in which he had given an evasive answer.
Farron said he had concluded that it was impossible for him to stay as leader of a progressive, liberal party and live as a committed Christian despite not seeking to impose his views on others.
"I seem to be the subject of suspicion because of what I believe and who my faith is in," he said. "In which case we are kidding ourselves if we think we yet live in a tolerant, liberal society."
The Liberal Democrats had joined the Conservatives in a coalition government led by David Cameron in 2010 after winning 57 seats. However, five years later they were routed and won just eight.
Farron had said his party would not support either May's Conservatives or the opposition Labour Party in forming a government after last week's election left no outright winner.
He will stay on in his job until the party starts the process of electing a new leader next month. Former Business Secretary Vince Cable and Jo Swinson, who was a junior minister in the coalition government, are the favourites to replace him.
Please click to read our informative text prepared pursuant to the Law on the Protection of Personal Data No. 6698 and to get information about the cookies used on our website in accordance with the relevant legislation.
6698 sayılı Kişisel Verilerin Korunması Kanunu uyarınca hazırlanmış aydınlatma metnimizi okumak ve sitemizde ilgili mevzuata uygun olarak kullanılan çerezlerle ilgili bilgi almak için lütfen tıklayınız.