A Ukip general election candidate has quit following revelations he endorsed offensive far-right messages posted online.
Donald Grewar apologised for his "foolishness" as he wrote to the party to withdraw from the contest for Newport East, in Wales.
The party launched an investigation following reports Mr Grewar had backed a post on the British National Party's website, which referred to gay people as "perverts" and "paedophiles".
The would-be MP also apparently backed a post by the English Defence League which called for "no surrender to militant Islam or political correctness."
In a letter to Ukip chairman Steve Crowther, Mr Grewar said: "I am sad to have to be writing this letter, but I have come to the conclusion that, following the revelation of some comments that I posted on the Internet a while ago that I have to reconsider my position as the PPC for Newport East.
"I recognise fully that those comments, and the implications of those comments, puts me in breach of the party rules. I had forgotten that I had posted them, but I had.
"I am truly sorry that my foolishness has caused you, the party and me embarrassment."
Mr Crowther told Mr Grewar he was "sorry" to lose him as a candidate, but said that he had "done the right thing."
He added: "Thank you for your hard work and commitment to the cause."
Additional reporting by PA
Join our new commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies