At that time of day when the light is fading and the streets are filled with homebound commuters, a spectral Dublin emerges. For an hour or so it becomes haunted by dead rebels and forgotten kings – the most melancholy and seductive city in which to walk through the twilight. The poet Louis MacNeice, a northern Irish protestant, came to Dublin as a visitor. He did not – could not – love the city. Yet he was unable to resist the power of her past.

Poems, plays, novels and stories inhabit the personality of Dublin in a way that I have never encountered in another city. Literary outpourings were first documented in the sixth century, with the Gaelic bards who wrote praise songs for the Irish chieftains: poetry was prized as, unlike earthly treasures, it was considered immortal. After the native poets came the Vikings in the ninth century, with traditions of sagas, and the Normans in the twelfth century, bringing with them an English tongue that the Irish would make their own.

As a child, writers and actors came to our home in the genteel suburb of Terenure to talk and declaim. My father, an Abbey Theatre actor, recited WB Yeats and shared stories of the writers he knew. He drank with Brendan Behan and the poet Paddy Kavanagh, sipping pints of stout and ‘balls of malt’ – small whiskeys. And on a long, lost night he met a future Booker Prize winner, Roddy Doyle, at a party held at Doyle’s parents’ house.

My earliest remembered Dublin landmarks are associated with writers: when my mother took my brother and sister and I into town, she would point out St Patrick’s Cathedral where its then-dean Jonathan Swift wrote Gulliver’s Travels or, bringing us to swim at Sandycove, would show us the Martello Tower, where James Joyce opened Ulysses. In homage to memory and the power of Dublin’s literary heritage, I offer my own pilgrimage through the worlds of some favourite Dublin writers.

Patrick Kavanagh
Kavanagh’s poetry evokes the city beautifully. In his 1953 poem If Ever You Go to Dublin Town, he asked the reader to seek out his presence long after his death: 

“On Pembroke Road look out for my ghost/ Dishevelled with shoes untied/ Playing through the railings with little children/ Whose children have long since died.”

I begin my search for Kavanagh on Grafton Street, a busy pedestrianised thoroughfare that thrums to the sounds of itinerant musicians. Here too is one of the great coffee emporiums of the literary world, Bewley’s Grafton Street Café, preserved in its old-world glory. Joyce mentioned it in his short-story collection Dubliners, and he, WB Yeats, Samuel Beckett and Kavanagh were all regulars.

Nearby, Kavanagh immortalised a brief meeting with the great unrequited love of his life, Hilda Moriarty (later O’Malley). A dark-haired beauty whom he met in 1944, she was, alas for Kavanagh, to marry a future government minister in 1947. He wrote her the poem On Raglan Road, later made famous as a ballad by the Dubliners:

“On Grafton Street in November we tripped lightly along the ledge/ Of the deep ravine where can be seen the worth of passion’s pledge.”

From Grafton Street I head south through Fusiliers’ Arch, into lovely St Stephen’s Green. There is a bust of James Joyce here facing his old university college, Newman House. With 22 acres in the middle of the city, it is the largest of inner Dublin’s parks. Here, during the Easter Rising rebellion of 1916, Constance Markievicz, scion of Anglo-Irish high society and friend of Yeats, commanded a small rebel force until British sniping from the nearby Shelbourne Hotel forced her and other rebels to retreat. During the fighting, both sides observed a truce to allow the groundskeeper to feed the ducks in the park’s ornamental lake.

A 10-minute stroll takes me out towards the Grand Canal at Baggot Street Bridge. This was Kavanagh’s favourite spot – a place “leafy-with-love banks and the green water of the canal pouring redemption for me”, as he wrote in 1958. The council erected a statue of the poet, seated on a park bench in eternal admiration of the passing swans, where I join him to read a Saturday copy of The Irish Times; the books page offers some of the best literary criticism in Europe.

Anne Enright
Enright is a very modern Irish novelist. She once said that, unlike other cities where clever people make money: ‘In Dublin, clever people go home and write their books.’ Anne did both: her haunting novel The Gathering won the 2007 Man Booker prize and became a bestseller. Although set in the kind of genteel Dublin suburb in which I grew up, her novel reaches beyond Ireland towards a universal terrain of loss:

“We each love someone, even though they will die./ And we keep loving them, even when they are not there to love any more./ And there is no logic or use to any of this, that I can see.”

In her previous, debut novel, The Wig My Father Wore, the narrator Grace uses the wig as a symbol of what is false in her own life and the Ireland which has shaped and distorted her: “For years my father’s wig felt like an answer. I could say ‘I am the way I am because my father wears a wig.’” To sample something of the intellectual world that shaped Anne Enright, I step into the calm, cobblestoned quad of Trinity College, where she was a student in the Seventies.

Founded in 1592, Trinity was for centuries a bastion of Protestant ascendancy in Ireland. The first Catholics were not admitted until the late 18th century. The Catholic Church viewed the institution with grave suspicion: until 1970, Catholics needed permission from their bishop to attend Trinity. The college is home to the Book of Kells, an eighth century set of gospels created by the monks of the Abbey of Kells in County Meath. A work of incredible beauty, the book helps to attract close to half a million visitors to Trinity College each year. Other bibliophiles come to spend a contemplative hour or two in the Long Room of the old Library Building – lined with thousands of volumes, and where the atmosphere is heavy with the grace of knowledge.

Walking past the busts of notable scholars, each with solemn visage gazing out from the distant past, I pass shelf after shelf crammed with learning. Yet the books on display are but a fragment of the Trinity collection. There are more than three million books in the repository, with extensive collections in the Irish language and a world-renowned children’s literature catalogue. Also here are the depositions taken following the Irish Rebellion of 1641. These feature interviews with Protestant survivors of the Catholic massacres and were used as justification by Cromwell for his notorious campaign later in that decade. The depositions were circulated in England to create public support for a punitive campaign against the Irish.

Emerging from the hush of the library and finding myself suddenly hungry, I make a beeline for Leo Burdock’s chipper. For nearly a century, Burdock and his descendants have served what Molly Bloom in Ulysses called ‘a nice piece of cod’ in crisp batter, with equally tasty chips. My favourite is the smoked cod, a Dublin staple, to be eaten across the road at the site of the old fish market on Fishamble Street, which entered musical history as the place where Handel’s Messiah was first performed at Neal’s Music Hall on 13 April 1742. Sat here in the open, I catch the scent of roasting barley blown downriver from the Guinness brewery at St James’s Gate. That is the smell of Dublin.

Walking east along the banks of the River Liffey and then turning north takes me to the greatest of Dublin’s five Georgian squares. Mountjoy Square was named after an Anglo-Irish peer who promoted the development of Georgian Dublin but died fighting against Irish rebels in 1798.

Sean O’Casey
It was here, on Mountjoy Square, that Sean O’Casey, one of the great figures of 20th-century European theatre, lived for a period in a tenement flat at number 35. These terraced, red-brick houses were first built for the city’s elite – lawyers, churchmen, politicians – but during the 19th-century decline of the Protestant ascendancy, their prominent inhabitants departed for London. Many houses became tenements, and by the early 20th century, around 20,000 families were living in one-room flats. Diseases like tuberculosis and rickets – the latter caused by malnourishment – were rife. As O’Casey, growing up in this atmosphere of poverty, caustically observed: ‘Money does not make you happy but it quiets the nerves.’ His best writing drew from the Dublin working class experience of the political turmoil that engulfed Ireland between the rebellion of 1916 and the Irish Civil War of 1922. In his play Juno and the Paycock, the mother of Johnny Boyle, shot by his colleagues in the IRA for informing, calls out to her dead son with words that echo down to the present day:

“Blessed Virgin, where were you when me darlin’ son was riddled with bullets, when me darlin' son was riddled with bullets? O sacred Heart o’ Jesus, take away our hearts o’ stone, and give us hearts o’ flesh! Take away this murderin’ hate, an’ give us – give us Thine own – Thine own eternal love!”

The architecture of O’Casey’s Dublin might have been cruelly eroded but for determined campaigning against the depredations of property developers in the 1960s: the Georgian city was seen as a symbol of a British past that some of our most powerful nationalist politicians were keen to bury. Since then, many of the buildings located around Mountjoy Square and its adjacent streets have been converted into flats or cheap hotels. It is still an area that struggles between the edgy and the elegant.

After an afternoon wandering the north inner city a degree of claustrophobia is creeping in, so I head to the nearest DART (Dublin Area Rapid Transit) station to catch a sea-bound train. The DART runs along the entire curve of Dublin Bay, passing regal Dalkey in the south, home to Bono of U2 and celebrated English foreign correspondent Robert Fisk, all the way north past the urban sprawl of Raheny and Kilbarrack, where Roddy Doyle set his novels of Dublin working-class life.

Roddy Doyle
Although his narratives often follow a tragic arc, Roddy Doyle is above all a very funny writer. His wit taps into a richly ironic Dublin tradition. It is a world in which a notorious hardman might hear someone shout, from a safe distance: “Come on ya coward and fight the nine of us!” His 1987 novel The Commitments tells the story of an aspiring rhythm and blues band on the city’s northside:

“They’d been in the folk mass choir when they were in school but that, they knew now, hadn’t really been singing. Jimmy said that real music was sex … And there wasn’t much sex in Morning Has Broken or The Lord Is My Shepherd.”

Passing the anonymous council estates on my left – the fictional Barrytown of his novels – and the glowering sea on my right, some of Doyle’s words about his native city come to mind: “It’s a big con job. We have sold the myth of Dublin as a sexy place incredibly well; because it is a dreary little dump most of the time,” he told a journalist in 2004. Only a man known to love his hometown with a deep passion could get away with a remark like that.

Doyle is a champion of the Dublin that stretches, physically and psychologically, beyond the concerns of the metropolitan elite. He lives near the DART line now, on the way to the busy fishing port of Howth. Along its busy quayside, trawlers unload their catch. Some of these fruits of the Irish coast go straight on ice at Wrights of Howth, a seafood store where smoked salmon is a speciality. Salmon has a special place in the folklore of Ireland. In the Fenian Cycle, a body of mythological poems and stories first written down in the seventh century, it was said that the great warrior hero Fionn Mac Cumhaill tasted the flesh of the Salmon of Knowledge as a boy, and in doing so gained all the wisdom of the world. On this basis, a side of Wrights’ smoked salmon seems a bargain.

Before catching the DART back to Dublin, I make a brief foray up along Howth Head – the ‘Himp of Holth’ in Joyce’s Finnegan’s Wake – as a pale sun emerges to light the sweep of the bay. East lies the little island of Ireland’s Eye, to the west the Wicklow Mountains. Beneath them in the valley of the Liffey, the great city awaits twilight. Across the bay are the tall chimneys of the power station in Ringsend, home of Paul Durcan, Ireland’s most exquisitely tender, richly comic and ferociously political poet.

Paul Durcan
I remember the subversive thrill of reading Durcan’s poems for the first time. I was still at school when he wrote of enjoying carnal pleasures outside the presidential residence, Áras an Uachtaráin, in Dublin’s Phoenix Park. Durcan’s poem was a challenge to the puritanical spirit of the times as embodied in the austere presence of Éamon DeValera, revolutionary founding father and president for some of the period when Durcan and I were growing up in Dublin.

The park is lovely in all seasons – a 1,740- acre mix of glen and woodland to the north of the Liffey where you can spot fallow deer and swooping sparrowhawks and kestrels, and picnic in the shadow of the giant Papal Cross. This 35-metre-high structure stands where Pope John Paul II addressed more than a million people in September 1979. I chose a spot under one of the park’s numerous trees and while away an hour with a copy of Daddy Daddy, my favourite of Durcan’s collections.

As darkness falls, my thoughts turn from the solitary wanderings of the day towards more convivial preoccupations. Heading out onto Parkgate Street at the southern end of the park, I walk to O’Donoghue’s pub on Merrion Row. With a history that dates back to the 18th century, O’Donoghue’s was the epicentre of Ireland’s folk music revival in the 1960s. There is still good music, flowing drink and an atmosphere of ease. The great folk singer-songwriter Andy Irvine, who arrived in Ireland from London in the Sixties and never left, immortalised the place in his eponymous ballad.

I grew up in Dublin between the mountains and sea. I feel the passion described by the poet Donagh McDonagh, who wrote of ‘this arrogant city that stirs proudly and secretly in my blood’. Pack your bag full of her writers and walk these streets and, I promise, the passion will stir within you too.

Correction: A previous version of this article incorrectly spelled Patrick Kavanagh's name. This has been fixed.

The article 'A literary pilgrimage through the streets of Dublin' was published in partnership with Lonely Planet Traveller.