Women of ruined reputations in the 18th century often ended up as prostitutes in brothels such as these in a painting by William Hogarth

Step east from Dublin Castle along the newly widened Dame Street and past the imposing façades of banks and lending houses of the city's Royal Mile. Unless you seek a night's entertainment in the taverns and playhouses of Smock Alley and Fishamble Street, do not venture left down those other narrow, medieval alleys towards the quays. There lies danger and vice. This evening, you will also forgo the gaming tables at Mr Buck Whaley's club at number 2-3 Dame Street; the pleasure you seek lies elsewhere.

The smell of horse dung is all that troubles the nose, for the filthy, ragged and impoverished mobs that gather in daily protest outside the elegant neo-classical House of Parliament on College Green have long since slunk home to their hovels. Figures dart furtively in the shadows. These will certainly not be unaccompanied females as no respectable woman is out alone after dark.

And, with any luck, nor will these shadowy shapes belong to the lower-order street gangs The Ormond Boys or The Liberty Boys, out to seek vengeance and bloody murder on each other; neither will they be the drunken, violent Pinking Dandies who, although gentlemen from your own privileged class, do not discriminate when it comes to assaulting passers-by just for the sport of it. Press on towards your destination across the river on Drogheda Street. For here lies a house of entertainment where food, champagne, pretty girls and the gratification of every sexual desire awaits. The proprietress, and your hostess for the evening, is the lovely Mrs Margaret Leeson.

In late 18th-century Dublin, any gentleman caller who had behaved honourably towards Mrs Leeson, and had fully paid up for services rendered by her and her girls, would have had little to fear from the first two volumes of her memoirs, published in 1795. They would not have been identified in the text; but cads and bounders would have been shaking in their fashionable breeches. In Peg Plunkett: Memoirs of an Irish Whore, biographer Julie Peakman claims her protagonist as the first madam to not only scandalously reveal the names, and sexual predilections, of her titled clients, but also shows the degree of power she acquired by doing so in an era when the majority of women had little control over their lives.

And did she have illustrious clients.

Many of the richest and most powerful players in the ascendancy are here, including at least two lord lieutenants of Ireland, and landowners with a mouthful of titles as ridiculous as their massive estates.

When she briefly became the 'kept woman' of one of them, Peg brazenly took and kept his surname as a form of compensation. Readers will not be surprised at the hypocrisy of the establishment, but perhaps at the sheer number of pillars of society she claims were involved. Our eponymous Irish whore with a modern outlook railed against the prevailing double standards of morality, writing: "Chastity, I willingly acknowledge, is one of the characteristic virtues of the female sex. But may I be allowed to ask - is it the only one?"

Peg's ultimate destiny as a prostitute and brothel madam could hardly have been less signalled given her gentrified beginnings. Born Margaret Plunkett near Delvin, Co Westmeath around 1742, her father Matthew Plunkett, believed to be a descendant of Blessed Oliver Plunkett, was an Irish Catholic whose property provided a comfortable income. His large family could also claim some aristocratic connection through their mother, a distant relation to the Earl of Cavan. Those early years 'glided on in the paths of innocence and content' but came to an abrupt end when Peg's brother, Christopher, took over as head of the Plunkett household.

His pathological violence is key to her downward spiral. Most women at that time were dependent on male relatives to provide and protect them. In Peg and her sisters' case, their sadistic elder sibling "frequently horse-whipped and beat us in the most savage manner".

To escape, she resolved to find a husband. The seduction, abduction and blackmail of young women from wealthy families by feckless men were a fact of 18th-century life. But Peg took little heed of this or of the fate of heroines of books that she would have read, such as Daniel Defoe's Moll Flanders and Samuel Richardson's Pamela; she too succumbed to the advances of a seducer who promised to marry her in the morning.

At a time when a woman's virginity was essential to secure respectable marriage, Peg, subsequently pregnant and ostracised by her family, was no acceptable catch for her Mr Dardis who could lose his own reputation, and his inheritance along with it.

Almost destitute by her early 20s, and having already given birth twice, Peg's fortunes changed on becoming the mistress of Joseph Leeson, the 2nd, 1st Earl of Milltown, former MP for Thomastown, self-styled Viscount Russborough, notorious womaniser, and 'depicted as a dunce in a painting by Joshua Reynolds'.

His official portrait, by Pompeo Batoni, which hangs in the Milltown wing of The National Gallery, is one of several colour reproductions in this fascinating book. Another by the same artist, Portrait of a Lady as Diana, was once believed to be of Peg but which Peakman's research now finds unlikely.

The Eton and Grand Tour-educated Milltown and his mistress divided their time between his Dublin residence on Ranelagh Road and his 'excellent house and beautiful demesne' in Kildare. The author believes that at this time, Peg would have been in the company of the Lennox sisters living on neighbouring estates at Carton and Castletown. In her future career, we're told that Peg would always keep a bed warm for Emily Lennox's son, William Robert Fitzgerald, 2nd Duke of Leinster.

Milltown cast her off when he discovered she was seeing other men. One of these was the well-connected but financially insecure Buck Lawless, the man she loved and bore five children with. Their years together in Wood Street were the happiest and most stable of Peg's life but ended in jealousy, debt, the premature death of all of the children, and her 30-year career as a prostitute.

How reliable is Peg's account?

Peakman, historian and fellow of the Royal Historical Society and honorary fellow at Birbeck College, tells us in her introduction that Peg rarely gave accurate dates, and had a tendency to skip over events she may have found boring in order to record the most titillating revelations. While largely relying on her subject's account and building her biography around that, meticulous researcher Peakman sets out to verify the facts while also filling us in on a city where revolution simmers just below that elegant surface.

This bawdy, entertaining biography can be read at so many levels, whether as a map of Georgian Dublin, a social history, the daily customs of a privileged household, a who's who of theatre, a record of fashion in dress and interiors, or a health account of makeshift contraception, endless childbirth and precarious treatment of rampant sexually transmitted diseases.

We read about the similarities of then and now, like the proliferation of coffee houses around the city. Or when Peg bravely takes a case against wealthy dandy Richard Crosbie, leader of the violent Pinking Dandies, whose assault caused her sixth child to be stillborn and he is let off by the authorities.

Money, as usual, says Peakman, would protect the guilty.

Memoir

Peg Plunkett: Memoirs of an Irish Whore

Julie Peakman

Quercus, hdbk, 256 pages, £20

Indo Review