J.K. Rowling has torpedoed multiple fan theories suggesting she came up with the idea for Harry Potter at a cafe in Edinburgh, Scotland.

The author took to social media this week to clear up rumours about the birth of her stories about the boy wizard and his friends, revealing she only started writing them down in The Elephant House.

"I was thinking of putting a section on my website about all the alleged inspirations and birthplaces of Potter," she wrote on Twitter. "I'd been writing Potter for several years before I ever set foot in this cafe, so it's not the birthplace, but I did write in there, so we'll let them off!"

Rowling went on to reveal she first scribbled down her ideas about Potter's wizarding world in London, adding: "I was renting a room in a flat over what was then a sports shop. The first bricks of Hogwarts were laid in a flat in Clapham Junction.

"If you define the birthplace of Harry Potter as the moment when I had the initial idea, then it was a Manchester-London train. I'm perennially amused by the idea that Hogwarts was directly inspired by beautiful places I saw or visited, because it's so far from the truth."

Rowling published The Philosopher's Stone, the first book from the sensationally popular novel series-turned-film franchise, in 1997.

The author has also shared a picture of a bookshop in Porto, Portugal, and responds to the owners' claims that it was an inspiration for Harry Potter.

"I never visited this bookshop in Oporto," she states. "Never even knew of its existence! It’s beautiful and I wish I had visited it, but it has nothing to do with Hogwarts!"

LATEST NEWS