David Cameron put the UK on collision course with Europe as he signalled he would fight plans to force the UK to give voting rights to prisoners.

The Prime Minister insisted the decision was one for MPs, not a "foreign court", after human rights judges issued an ultimatum giving Britain six months to change the law.

He told MPs he backed their overwhelming vote last year that effectively opposed the European Court of Human Rights (ECHR) ruling.

At Prime Minister's Questions, he said: "I have always believed when you are sent to prison you lose certain rights and one is the right to vote.

"Crucially, I believe this should be a matter for Parliament to decide, not a foreign court. Parliament has made its decision and I agree with it."

Labour said it would back Mr Cameron if he opposed the ruling. Shadow Chancellor Ed Balls said there was cross-party agreement about not giving the vote to prisoners and the ECHR ruling was the "wrong thing".

"This is one of those times in politics where there is cross-party consensus," he said.

"I am all in favour of prisoners having the right kind of support and being rehabilitated but voting is one of the things I think you give up if you go to prison."

The ECHR acknowledged that it was up to national authorities to decide exactly who could vote from jail, but said denying the right to all inmates indiscriminately was illegal.