A former first minister and the leader of the Kirk have appealed for the final phase of the referendum campaign to be spared further bile and vitriol.

Henry McLeish and the Right Rev John Chalmers, Moderator of the General Assembly of the Church of Scotland, spoke out after a torrent of online abuse followed author JK Rowling's intervention in the ­independence debate.

Steven Camley's cartoon

The representatives of civic Scotland said both sides needed to become more respectful of opposing voices in the wake of the "cyberstorm" that greeted the announcement by the Harry Potter creator that she was donating £1 million to Better Together.

The author's donation, and her blog outlining her reasons, resulted in an explosion of comments on Twitter and other social media, although one of the most incendiary contributions was disowned by the charity involved, which claimed its Twitter feed had been hijacked.

Mr McLeish said he was appalled at the conduct of some people engaged in the debate.

"There is no justification for this behaviour and it does the country a disservice," he said. "For the next three months give it a rest. Get out on the doorsteps and off your computers.

"I love politics and love my country. We have just celebrated the anniversary of D-Day and retaining our democracy and freedom. Seventy years on we don't need cyberspace filled with personal bile and poison."

Rev Chalmers said last night: "Personal insults have no part in the discussion about Scotland's future. Some of what I am hearing from both sides in the campaign represents my worst fear as decision day draws closer.

"I urge both sides of this debate to turn the volume down, stick to facts and principles and remember that on September 19 there will be no 'us and them', only us."

Rowling previously donated £1m to the Labour Party and is close to Gordon and Sarah Brown. She also appeared at a pro-Union gig by the comedian Eddie Izzard, so her support for the cause was well known.

Many of the Twitter responses to her announcement were abusive, prompting responses from the pro-­independence camp seeking to dampen down the flames.

A Tweet from the Dignity Project, an Edinburgh charity involved in work in East Africa, said: "What a b**** after we gave her shelter in our city when she was a single mum."

The group later announced: "We are not responsible for any tweets that have been sent. As a charity we do not take any political stance and our opinion is people are free to donate to whoever they choose."

A spokesman for Yes Scotland said: "While we may disagree with her views, we of course completely respect JK Rowling and her right to express her opinion on the referendum and donate to the No campaign."

Shadow Scottish Secretary Margaret Curran welcomed Rowling's stance on independence and criticised the "vile abuse". She added: "This has to stop. It's time to let people speak their minds freely without any fear of retribution."

At Westminster, David Cameron came out strongly against the cyber-attacks on Rowling. The Prime Minister's spokesman, when asked about the Twitter abuse against the author, replied: "There is no place for abusive behaviour in whichever sphere of life, so it's important to be clear about that."

Treasury Chief Secretary Danny Alexander said: "Alex Salmond should be making a clear statement that it is not in Scotland's interest for dissenting opinions to be silenced through intimidation and fear, and order this behaviour to stop."