PICTURE life as a series of forks in the road. Each decision, no matter how small or seemingly inconsequential, closes the door on one existence and forges ahead into another. Yet, at the same time, the path left behind quietly splinters off and is lived by another version of you.

Now imagine if there came an opportunity to go back and revisit all of those infinite lost, squandered and forgotten possibilities. Would you find a sense of peace in an alternative timeline or be forever haunted by what might have been?

That's the question posed by The Midnight Library, the latest novel by Matt Haig. It centres on Nora Seed, a woman who is hopelessly adrift and wants her life to end. Instead, she awakes in a library, hovering in a curious existential limbo, neither alive nor dead (think Schrodinger's cat, physics fans).

Each book on the library's shelves represents a chance to confront her regrets and see how things might have turned out had she not embarked upon a certain path in her "root life". And, as she does so, Nora finds the answers to the questions that have long weighed heavy on her mind.

What if she had never given up her childhood pursuit to become an Olympic swimmer? Should she have followed her music dream to make it as a famous rock star adored by millions? How would things have panned out if she had never left the boyfriend who wanted to open a country pub with her?

The Midnight Library allows Nora to live out all of those possibilities and more – often with surprising outcomes. "I have wanted to write about parallel lives for a long time," says Haig. "I was just waiting for the right idea."

Does he believe that parallel lives exist? "I kind of do," he says. "Increasingly science seems to back it up as well. I think there are all kinds of scientific reasons for some sort of parallel existence out there."

Haig is warming to his theme. "I have always been obsessed with it," he continues. "Especially nowadays when we live in this age of constant comparison, which is exacerbated and accelerated by the internet and social media.

"People are continually comparing their lives to other people's lives. And the lives they are comparing them to might not necessarily exist – they are just presented that way on social media.

READ MORE: Doug Johnstone on how spending time with a funeral director inspired his latest novels

"We are often doing hypothetical things where we are punishing ourselves for not having a certain life or body or perfect relationship. We are almost encouraged to feel bad about ourselves."

The 45-year-old author, whose books include How To Stop Time and Notes On A Nervous Planet, says he wrote his new novel in the spirit of the 1946 film It's A Wonderful Life, hoping to impart a message about "acceptance and realising that often you have a lot more than you think".

Regret is a feeling Haig knows well. With the publication of his 2015 memoir Reasons To Stay Alive, he laid bare the severe depression and spiralling anxiety that led to a breakdown and suicidal episode in his early twenties.

Haig was 24 and living in Ibiza with his now wife Andrea. Next month marks 21 years since the day when, feeling utterly powerless within the grip of such dark, debilitating thoughts that he was unable to see a future for himself, Haig stood on the edge of a cliff preparing to jump.

He wrote about his journey back to life in Reasons To Stay Alive. The book was meant to be a side project in between Haig's fiction works but struck such a chord that it became a UK No 1 bestseller and was published in 29 countries (it has enjoyed another surge of sales during lockdown).

It is impossible not to draw parallels – pardon the pun – between his experiences and those of Nora in The Midnight Library. When writing the book, Haig admits to ruminating on the many forks in his own path. If, like Nora, he had the chance, which ones would he revisit?

"Often it has been mental health-related with me," he says. "I had a bad time in my twenties where I was full of regrets. I was regretting the lifestyle that led me to depression, I was regretting all the decisions I had made, and I was regretting having made the wrong career choices at that point.

"For many a year, when I was a struggling writer, I regretted being a writer. I got there in the end, but it wasn't an instant success story. There are lots of regrets, but I think I'm much more philosophical about it all now."

HeraldScotland:

Haig believes he emerged from his breakdown better equipped to appreciate life. "I wasn't a particularly happy child or teenager or young adult," he says. "Then I was ill for most of my twenties and recovering into my early thirties.

"I still have the odd mental health dip now. My mental health is not in a perfect place ever – it is always on the scale somewhere – but I genuinely know more contentment, happiness and gratitude this side of my breakdown than I ever did when I was younger."

Today, Haig lives in Brighton with Andrea and their two children. While many people knew his books before, there are those who have newly discovered Haig, thanks to his thoughtful words of reflection during the ongoing coronavirus pandemic.

He has become something of a figurehead for mental health. It is a mantle Haig isn't always comfortable with ("often when I am talking inspirationally, I won't necessarily be in a perfect state of Zen or calmness") yet is unabashedly delighted to learn when his words do help others in pain.

Haig is prolific on Twitter and Instagram, where he regularly gains attention for his astute observations on current affairs, mental health issues and a raft of sometimes poetic, mostly withering, jabs at Donald Trump ("God I hope they get rid of President F***face" being one such tweet last week).

Describing his posts as brave, prompts a wry laugh. "Brave/stupid," says Haig. "Sometimes on Twitter I forget that I have quite a few people following me now. I have always been a strange combination of sensitive but also opinionated. It is not like I am immune to criticism.

"As soon as you get a blue tick and a few thousand followers, it's like people think, 'Oh well, they are fair game …' I have learned to be a little bit more philosophical about it. There are people who, when they go on Twitter, switch from person to person, and it is just attack, attack, attack.

"A great tip to dealing with Twitter is before you take that one personal insult to heart, go look at their tweets to see what type of person they are. Nine times out of 10 it will make you feel better."

READ MORE: Five must-read Scottish books headed for TV and film

The author is as warm and affable to speak to voice-on-voice (this being a phone interview) as he comes across in his writing. Despite proffering sage words of wisdom, Haig admits he has struggled through lockdown as much as the next person.

He is finding this current period particularly tricky. "Because it is summer and I'm such a person who lives for holidays, restaurants and getting away. I have realised that I don't have those little markers in my calendar of things to look forward to."

However, Haig and his family have been finding other ways to have fun. "I'm a movie geek and so I try to get them [his children] into movies. We are going through all the James Bond movies. We are onto Roger Moore at the moment. I've been explaining there is quite a bit of sexism in them.

"Also, we have an electric keyboard and are using an app to learn the piano and competing with each other on that. That is one of the things we have filled lockdown with.

"Basically, I try to get them excited about stuff because they teach me about Xbox-related things. I'm literally the world's worst player of video games. It is laughable how rubbish I am."

Haig has another book in the pipeline. "It is going to be called The Comfort Book," he says, adding that it will be "less specifically about mental health" and "more about how we can accept ourselves and imperfection, and feel comfortable with who we are."

In the meantime, you can likely find him hanging out on social media. Although perhaps not forever. "I do think probably, on balance, Twitter isn't a force for good," he muses. "It's not really making society or the world any better.

"I do possibly dream or imagine a day where I will walk away from all social media. I'm sure it will happen at some point. I have a love-hate relationship with it."

The Midnight Library by Matt Haig is published by Canongate, priced £16.99