Rome Mayor Ignazio Marino resigned Thursday following a scandal over his expense accounts that became the convenient final straw in a months-long campaign by opponents inside and out of his Democratic Party to force him from office.

Marino said in a letter addressed to Romans that his resignation was not an admission of guilt and he cited Italian law that says he could rescind it within 20 days.

He insisted he was being made the fall guy for having rooted out corruption and mafia infiltration in city hall from the previous administration, and vowed to expose the truth.

Rome prosecutors this week opened an investigation into Marino's use of his city hall credit card after questions arose about whether he expensed family dinners, claiming they were official business.

Newspapers documented a half-dozen dinners totalling a few hundred euros (dollars) where either the alleged guests or the restaurant itself disputed Marino's version of events.

Marino, a liver transplant surgeon who became a politician a decade ago, denied wrongdoing. But as pressure mounted Wednesday, he promised to pay the entire 20,000-euro ($22,600) credit card bill, including uncontested legitimate expenses, back to the city.

It wasn't enough.

His Democratic Party, which had been lukewarm to his administration for months anyway, finally yanked its support and made clear that he had lost his mandate.

Marino had been increasingly isolated by his party -- and Premier Matteo Renzi -- and saw his popularity plunge following a series of scandals and corruption probes involving Rome's public administration, most of them concerning alleged wrongdoing under his predecessor, the centre-right's Gianni Alemanno.

A massive investigation over the awarding of public works contracts has implicated politicians and businessmen from both right and left, including Alemanno himself.

Marino was never implicated and was instrumental in reporting the wrongdoing to prosecutors.

Rome's corruption has long thrived on the connivance of city politicians, administrators and local gangsters who divvy up city contracts, skirting public bidding procedures and with the wrongdoers pocketing kickbacks or bribes. That largely went undetected until probes intensified under Marino's watch, suggesting that his downfall was at least in part the result of having exposed and helped overturn the way things are done here.

In his farewell letter, Marino vowed to find the truth despite harbouring a "serious fear" that city hall would return to its past "of speculation, illegal private interests, of a corrupt-mafia mechanism" that he said threatened to bring down more than just the party.

Despite the obvious political mechanisms behind his ouster, Marino has been responsible for some of his own undoing.

Last year, he faced pressure to resign after he let parking fines pile up for his red Fiat Panda, which was repeatedly parked in the city centre without a permit. Marino, who mostly gets around town on his bike, blamed careless aides for letting the permit expire.

Over the summer, Marino was harshly criticized for staying on vacation in the U.S. while Rome erupted in outrage over a Hollywood-style funeral for a purported organized crime boss that included a police escort. For many, it was a display of opulence at a time when the city's basic services like public transport and garbage pickup were being neglected by strikes, mismanagement and cutbacks.

More recently, even the Vatican lost confidence in his ability to govern.

Pope Francis appeared visibly irked by Marino's reported suggestion that he had been asked by the Vatican to attend the pope's big final Mass in Philadelphia, the culmination of his recent U.S. tour. In a news conference coming home, Francis made clear that neither he nor the organizers of the church's Catholic family rally had invited him.

Subsequently, the Vatican official who co-sponsored the Philadelphia event was caught on a prank phone call disparaging Marino and questioning whether he could get Rome ready for the millions of pilgrims expected to come for Francis' Jubilee Year of Mercy, which begins on Dec. 8.

Marino was elected mayor in 2013, promising to bring order and function to Rome's chronically dysfunctional public administration. Some of his early moves endeared him to the public -- the bike, for example. But he also took some unpopular decisions, including closing a main thoroughfare through Rome's iconic Foro Imperiali to cars, further snarling the centre's congested traffic.

He also had a cloud hanging over him concerning a previous expense account scandal.

Marino, who had worked as a surgeon and researcher at the University of Pittsburgh Medical Center, left the U.S. to pioneer a transplant hospital in Sicily that was affiliated with Pittsburgh. But he abruptly resigned in 2002 as director of Sicily's ISMETT centre.

The U.S. institution said at the time that hospital auditors had found a pattern of "intentional duplicate" expense accounts submitted by Marino.