Stories live on all of humanity’s lips, from a mundane report of a day’s work to the terror witnessed in Gaza. We are all storytellers. But what good is creativity during times like these?

Global uncertainty set author Elif Shafak on a search to renew her faith in storytelling. Returning to the work of 19th-century French writer Gustave Flaubert, she found solace in thinking that “the 19th century is not over yet”. Flaubert’s France was a “time of war, civil war, siege, starvation, brother killing brother” though in modern times the “same thing is happening 1792308145” the Booker Prize shortlisted author says.

“Of course,” she acknowledges, “we have new challenges, but this feeling that the world is unravelling is not a new feeling.”

There is hope, extended from Flaubert to the modern reader, through the medium of Shafak.

In her latest novel In One Brief Moment All Eternity, the Turkish-British author imagines the life of the French writer and how he came to write Madame Bovary – dubbed the most scandalous woman in literature.

Flaubert is a “connoisseur of the female mind”, Shafak said, “but, I wanted to take that premise, turn it upside down.”

The novel’s jewel in the crown is the imaginative exchange between Flaubert and his creation, Emma Bovary. Shafak’s Emma yearns for a life beyond what Flaubert wrote for her. In the book, Emma says she “descended into a nightmare” as Flaubert types “paragraph after paragraph of agony” for her. Speaking back to Flaubert, Emma says he is “arrogant and self-absorbed” and that novelists “fancy themselves as miniature gods”. She then asks: “What if multiple women were to tell the story of one man’s life?”

In a knot of metafictional deliciousness, Shafak sets out on Emma’s wish: to write a novel with a chorus of women who tell the tale of the making of one man.

There are layers upon layers of questions to be asked about this as a premise, yet the most pressing is this: Do novelists have to be a little eccentric or a touch mad to believe they can create an entire world? Shafak’s Emma thinks so, yet Shafak herself says: “We all have inflated egos, and maybe as artists you need that, but you also need to learn to balance that. It’s a struggle. Some days we do it better. Some days we fail miserably.”

[ Elif Shafak: ‘I wanted to honour water. I think water is the story of our times’Opens in new window ]

In In One Brief Moment All Eternity, Shafak creates a new world to give voice to women – imagined and real – to tell Flaubert’s story. In one chapter, opium speaks, in another a corpse. But it is the real women, who were largely forgotten, that drew me in as a reader. Julie, Flaubert’s nursemaid growing up, gifted him a love of storytelling, while Kuchuk Hanem, a bellydancer, is a woman who is “at the heart of Madame Bovary”. The writer said: “She has been to a large extent forgotten, literally written out of history, reduced to a few lines in some biographies of Flaubert.”

Shafak immersed herself in researching the political and cultural history of the 19th century, unearthing letters and pamphlets that unlocked ideas that became fully fleshed scenes in the book. Through his letters, the novelist discovered that 27-year-old Flaubert travelled through Egypt, where he had a sexual relationship with Hanem, and in his writings he “talks about how they slept holding hands”. Shafak said: “I wanted to hear the voice of [Hanem] and to dig that voice from where it had been buried under the layers of history books.”

Many of these bellydancers – known as ghawazee – were courtesans, who had been exiled from Cairo to Esna due to their erotic dancing in 1834. Ghawazee were often hired to entertain men, and were the subject of scrutiny among those who deemed their dancing improper. Perhaps it was Flaubert’s experience with Hanem and her displays of desire amid the backlash of society that went on to inspire Emma Bovary.

The name ‘Kuchuk Hanem’ translates from Turkish to ‘little lady’, and has been the subject of critical discussion on whether this name was in fact her own or one selected to appeal to colonial western travellers. On East and West relations, Shafak argues for a porous approach, not one fashioning itself to appease and appeal to the other, but rather a melding of the two, as one informs the other.

She says: “We tend to think of East and West as mutually exclusive, monolithic categories. That never was the case, and especially as we go back in time [to Flaubert and the 19th century], they [those from the East and West] were constantly talking to each other, touching each other, influencing each other. Stories travelled beyond borders, people travelled, ideas travelled, and we tend to forget that European literature has also been influenced by Middle Eastern literary heritage and cultural heritage.”

The fluid movement between both narrative voices and geographical locations reflects the novel’s expansive imaginative power. Shafak calls for greater freedoms of authors to write beyond “what they know”. “In the age we’re living in, the autobiographical aspect of literature is overemphasised … [It] is a very limited way of looking at fiction. We sometimes write what we want to know. We write what we feel in our soul. The heart is always bigger than boxes of identity.”

We should be free to write wherever our hearts [and] our pens take us. Literature is one of our last remaining democratic spaces where we can slow down, have calmer, nuanced, multilayered conversations

When writing and reading, Shafak is interested in the “transcendental” capabilities of literature. She explains that stories should allow both writers and readers to engage in what the author Iris Murdoch called “unselfing”, the process of entering into another person’s psyche through fiction. Yet, she says, “If you happen to be an Afghan woman novelist, almost no one in the publishing industry expects you to write sci-fi or avant-garde fiction. You are expected to write about the problems of women in Afghanistan.”

Strict conventions to “write what you know”, she argues, are counterproductive: “Flaubert wrote one of the most iconic female characters, as did Tolstoy write one of the most iconic female characters. So, we shouldn’t lose sight of how we surpass the limits of the self.”

There is an echo between Shafak’s life and Flaubert’s. Flaubert was put on trial for obscenity in Madame Bovary in 1857, and almost 150 years later in 2006 Shafak faced a strikingly similar experience when the Turkish state brought a case against her over her novel The Bastard of Istanbul. Shafak explained that the mention of the Armenian genocide within the text – which she said is still “taboo” – went against the Turkish constitution, which protects “Turkishness against insults”.

“The truth is nobody knows what that means. So, it’s quite open to interpretation or misinterpretation … That article had been used primarily against journalists and historians, but never ever before against a fiction writer, so I found myself in a very honestly Kafkaesque situation in which the words of my fictional characters were plucked, were just taken out of the manuscript of the text, and used as evidence in the courtroom,” she says.

“My Turkish lawyer had to defend my Armenian fictional characters. That went on for over a year, during which time there were ultranationalist groups on the streets, burning my pictures, burning EU flags, spitting at my pictures. They were saying that I was the pawn of western powers. You know, I was acquitted eventually, but it was a very unsettling time.”

Another two of her books – The Gaze and 10 Minutes 38 Seconds in This Strange World – have since been investigated for obscenity, the same accusation that was levelled against Flaubert.

[ Elif Shafak: ‘If we want to see how connected we are, we should look at the journey of a single raindrop’Opens in new window ]

Shafak is a fierce advocate of artistic freedom. “We should be free to write wherever our hearts [and] our pens take us. Literature is one of our last remaining democratic spaces where we can slow down, have calmer, nuanced, multilayered conversations.” Not least as, she said, “This is the age of three As. It’s the age of anger, anxiety, and AI. But if it were to become the age of four As, if apathy were to be added into the equation, it would have been a much more difficult world to live in. Literature is the antidote to apathy.”

In a world where stories are doubted and discredited through disinformation campaigns, there is an urgent need for writers to be what Shafak terms “memory-keepers”.

“Without stories, people are unfortunately reduced to numbers. When we hear the news that 5,000 people died, our minds do not process the enormity of what we’re seeing, and then we just scroll up and down, and we move to the next news, and then the next news. It doesn’t stay with us. We don’t process it. It causes immense apathy.”

She is worried about what a world without stories would look like. She believes writers and literary festival programmers are at the coalface in creating spaces where listening to stories can be an act of resistance against apathy. That means listening especially closely to writers living through conflicts such as Gaza, which an independent UN panel called a genocide.

“So, when it comes to Gaza, it’s so important that we hear the stories. We listen to Palestinian authors today more than ever.” The same, she argues, should apply to writers elsewhere: “We [need to] hear the voices of Ukrainian writers, of storytellers from Sudan. We have to become listeners.”

For Shafak, there are also reasons to be hopeful about the future of literature. She credits the people who help books reach readers. “If books are still being read, if novels continue to somehow survive and thrive, we owe it primarily to booksellers who keep talking about books wholeheartedly. We owe it to librarians. We owe it to translators. They give so much, and they make it possible for books to travel beyond borders.”

Aimée Walsh is a novelist, journalist and book critic.