A key backer of Northern Ireland's 1998 peace accord and a Nobel Peace Prize winner, Trimble decided to quit after his party's worst performance in British parliamentary elections on Thursday.
The party that once dominated politics in the predominantly Protestant territory retained just one of Northern Ireland's 18 seats, and the highest-profile loser was Trimble himself.
In a statement on Saturday, the 60-year-old said he told senior party colleagues, "I do not wish to continue as leader."
The Ulster Unionists declined to explain when Trimble's resignation would take effect or when the battered party's grassroots council would convene to elect a successor.
Trimble's most probable successors also suffered defeats versus the Democratic Unionist Party, which has mobilised growing Protestant hostility to the 1998 accord and Trimble's support for it.
Analysts credit Trimble with taking many gambles before and after the complex Good Friday pact, which proposed dozens of goals designed to promote peace and reconciliation after a three-decade conflict over the British territory that has left 3600 dead.
Northern Ireland polarised
Today, Northern Ireland is deeply polarised but largely peaceful.
"History will show that without David Trimble's period as leader of the Ulster Unionist Party, Northern Ireland could never have become the changed place it is today," said British Prime Minister Tony Blair, who won a third term in Thursday's vote.
"Throughout he showed real leadership, vision, courage and a sheer dogged determination, despite all the difficulties involved in the search for peace," Blair said.
"Without him, there would have been no Belfast agreement. It would not have been possible to bridge the deep divide in Northern Ireland."
"History will show that without David Trimble's period as leader of the Ulster Unionist Party, Northern Ireland could never have become the changed place it is today"
British prime minister
When he was elected Ulster Unionist leader in 1995, Trimble - a former law professor at Queen's University of Belfast with a shy, bookish manner - was considered the most hardline candidate on offer.
He had risen that year to national prominence by championing the rights of Northern Ireland's major Protestant brotherhood, the Orange Order, to parade past hostile Catholic neighbourhoods each summer.
But soon, Trimble was walking down unexpected roads of his own and becoming a hate figure among Orangemen.
Crucially, while other Protestant parties boycotted negotiations involving Sinn Fein, the party linked to the outlawed Irish Republican Army, Trimble kept the Ulster Unionists at the table.
Good Friday deal
Trimble backed the Good Friday deal in 1998 and immediately split his party down the middle.
The pact called for Protestants and Catholics, including Sinn Fein, to form a power-sharing administration; for convicted members of the IRA and other truce-observing paramilitary groups to be freed; and for those groups to disarm fully by mid-2000.
Protestants expected the IRA to disarm as the price for Sinn Fein's involvement in government, but the IRA refused.
Trimble - who received the Nobel Peace Prize alongside Catholic leader John Hume - rallied Protestant support with the slogan: "No guns, no government."
DUP chief Ian Paisley (C) says
Trimble 'dug his own grave'
But after a 17-month deadlock, Trimble dramatically announced he would "jump first" and formed, in December 1999, a four-party coalition including Sinn Fein.
To the disgust of many Protestants, the administration included a reputed IRA commander, Martin McGuinness, as education minister.
Britain soon freed remaining IRA prisoners and began a painstaking reform of Northern Ireland's mostly Protestant police force, both moves opposed by Protestants, but the IRA refused to disarm in reply.
Trimble repeatedly took the administration to the brink of collapse in showdowns with the IRA, which finally scrapped an unknown amount of weaponry in October 2001.
But the delay, and the IRA's insistence that its handover of arms remain secret, proved deadly to Trimble's political base.
Protestants appeared just as unsettled with the popular growth of Sinn Fein, which rapidly overtook the Social Democratic and Labour Party (SDLP) among Catholic voters.
Reflecting that trend, Sinn Fein won five parliamentary seats on Thursday, the SDLP just three.
Trimble narrowly survived several attempts to unseat him as Ulster Unionist leader; but he could not stop the flow of votes to Ian Paisley's Democratic Unionists.
Gerry Adams's Sinn Fein wants
a united Ireland
And power-sharing finally collapsed in October 2002 from accumulated tensions between the Ulster Unionists and Sinn Fein.
Paisley, 79, landed the killer blow on Thursday, when his party won nine seats including Upper Bann, a district southwest of Belfast that Trimble had held since 1990.
Trimble, speaking to the BBC hours before issuing his resignation statement, blamed the Sinn Fein-IRA movement for fatally undermining his position.
He said the IRA should have disarmed fully by May 2000.
"That is what they undertook to do. That is what they failed to do," he said. This bad faith, he said, fuelled "total disgust in the [Protestant] unionist community with them."