Michael Gove is to launch an investigation into Rotherham council social workers removing three children from foster parents who are Ukip members. ITN

The education secretary, Michael Gove, has said he will launch an investigation into a council that removed three children from foster parents due to concerns about their membership of the UK Independence party.

The announcement came as Rotherham metropolitan borough council said it was launching an internal investigating into the decision, following mounting condemnation from political leaders including Gove and Labour leader Ed Miliband.

Gove branded the council's actions as "indefensible" and said he would be personally investigating the situation.

The council has acknowledged that the three children, who are European migrants, were happy with the unnamed couple and there were no concerns about the care they were providing.

Social workers said there were concerns about the "cultural and ethnic needs" of the children due to the couple's membership of Ukip.

Gove said social workers had made "the wrong decision in the wrong way for the wrong reasons".

The minister, who was himself adopted as a child, accused Rotherham of sending out a "dreadful signal".

"Rotherham's reasons for denying this family the chance to foster are indefensible. The ideology behind their decision is actively harmful to children.

"We should not allow considerations of ethnic or cultural background to prevent children being placed with loving and stable families.

"Any council which decides that supporting a mainstream UK political party disbars an individual from looking after children in care is sending a dreadful signal that will only decrease the number of loving homes available to children in need."

Roger Stone, leader of the council, said: "We are going to investigate to make sure everything has been done professionally.

"If the professionals give advice, we take it. We are going to investigate – we always would if somebody complains."

"We are looking to make sure all the correct procedures were carried out before the decision was made.

"There is no policy, as has been implied, that if you are a British National party member you can't foster children."

Ed Miliband called for an urgent investigation into the case.

He said: "Being a member of Ukip should not be a bar to adopting or fostering children. We need loving homes for children across the country. That can come in different forms, it's not about what political party you are a member of."

The unnamed South Yorkshire couple, who have looked after about a dozen children – all from ethnic minority backgrounds, told the Daily Telegraph that social workers had accused them of belonging to a "racist party".

Ukip leader Nigel Farage described the council's stance as "a bloody outrage" and "political prejudice of the very worst kind".

Joyce Thacker, strategic director of children and young people's services at the council, told the BBC Radio 4's Today programme: "The fact of the matter is I have to look at the children's cultural and ethnic needs. The children have been in care proceedings before and the judge had previously criticised us for not looking after the children's cultural and ethnic needs, and we have had to really take that into consideration with the placement that they were in."

Asked what the specific problem was with the couple being Ukip members, Thacker told BBC Breakfast: "We have to think about the clear statements on ending multiculturalism for example.

"These children are from EU migrant backgrounds and Ukip has very clear statements on ending multiculturalism, not having that going forward, and I have to think about how sensitive I am being to those children."

She added that there was no issue about the quality of care the couple provided and said she would co-operate with any investigation.

The wife told the Telegraph that she had asked the social workers what Ukip had to do with the decision. "Then one of them said, 'Well, Ukip have got racist policies'. The implication was that we were racist. [The social worker] said Ukip does not like European people and wants them all out of the country to be returned to their own countries.

"I'm sat there and I'm thinking, 'What the hell is going off here?' because I wouldn't have joined Ukip if they thought that.

Farage said he was "very upset and very angry" with the decision, and defended the couple as "very decent people".

He said they had suffered "the awful shock … of having these children removed, not to mention the upset to the children themselves."

The MEP also accused the Labour-controlled council of bigotry towards his party.

The chief executive of the Fostering Network, Robert Tapsfield said: "This may turn out to have been a bad decision – on the face of it, it seems to be one … The law is very clear the councils have to take in a range of factors, including ethnicity, when considering suitability for foster parenthood, but it is not relevant to ask potential parents about their membership of political parties. They get asked about how they propose to meet the needs of children they are going to look after, and ethnicity is one factor in that, but there are many others."

John Simmonds, BAAF director of policy and practice, said: "It would be extremely unusual for a foster carer's political views to play any part in this decision-making unless there was direct evidence that these views were detrimental to the care of the child."