Nicola Sturgeon has urged SNP members not to campaign for former candidate Neale Hanvey, who has been suspended over alleged anti-Semitic language in social media posts.

Mr Hanvey has been dropped by the party in Kirkcaldy and Cowdenbeath – won by Labour’s Lesley Laird in 2017 – while an investigation takes place but he will remain on the ballot paper.

Speaking for the first time about the suspension, Ms Sturgeon called for local SNP supporters to campaign in neighbouring seats, stressing her party “unfortunately” no longer has a candidate contesting the seat.

“My message to SNP members and activists would be to campaign in neighbouring constituencies,” Ms Sturgeon said.

“They’re not too far away from Stephen Gethins in North East Fife, for example, so there’s plenty of good candidates out there to get out and campaign for.”

An investigation into Mr Hanvey’s actions has been launched by the party and, asked what would happen if he won the seat, Ms Sturgeon said: “He’s suspended at the moment, there’s disciplinary action that will flow from that and it would not be appropriate for me to comment while that’s ongoing.”

Ms Sturgeon also addressed speculation Mr Hanvey may have been axed because of his views on trans rights.

She said: “He was suspended because of the anti-Semitic comments he made and that is the long and short of it.”

Mr Hanvey last week apologised “unreservedly” for any offence caused by the social media posts made two years ago.

He said: “Although I do not in any way consider myself anti-Semitic, on reflection the language I used was, and this is clearly unacceptable.”

With Labour leader Jeremy Corbyn also facing scrutiny for his party’s response to anti-Semitism allegations, Ms Sturgeon said she would make clear she would not tolerate discrimination if the parties were to work together after the General Election.

She said: “My position on anti-Semitism is clear, I’ve been very vocal about my views on Jeremy Corbyn and Labour’s lack of leadership on this.

“We take a zero-tolerance approach and I think we’ve demonstrated that and my message to anybody the SNP was thinking about working with – or the people who wanted to work with the SNP – is that a very-firm approach to anti-Semitism, to Islamophobia, to racism, to discrimination in all of its forms, is absolutely essential.”