The constitutional crisis predicted for years by Professor Vernon Bogdanor is upon us. He warned that the human rights reforms of the 1990s created a potential conflict between the sovereignty of parliament and the rule of law. "What happens if there is a clash between the two principles?" he asked in his Magna Carta lecture of 2006. A very senior judge to whom he had posed the conundrum had replied "That is a question that ought not to be asked."

The UK have until the 22 November to respond to the verdict of the European court of human rights on prisoner voting; it is no longer possible to avoid the dilemma.

Thankfully, a judge of that court in Strasbourg has outlined to me a promising answer. Moreover, there are signs from the Strasbourg bureaucracy that the Council of Europe anticipates the House of Commons will refuse to accept the court's verdict on prisoner voting and that the Council, the parent body of the court, is prepared for a considerable period of negotiation.

If the UK is resolute in defending its sovereignty by refusing to kowtow to Strasbourg, I do not believe that any dire results will follow. Indeed, Strasbourg will come to see as being in its interests to give way on the fundamentally important issue of national independence. By sacrificing the aim of exercising absolute legal authority over 47 nation states, the European court of human rights stands to gain in moral authority. By aiming for less, it will gain the respect and legitimacy which it currently lacks.

Were the prisoner franchise issue faced by the UK parliament really about the voting rights of incarcerated persons, it would be fairly simple to resolve. The court has made it plain that the UK needs to agree to the most minimal form of compliance with the Strasbourg judges' decision that there cannot be a blanket ban on prisoner voting.

But recognition of the authority of Strasbourg, however flexibly exercised, is precisely what many MPs are now unwilling to give. If the House of Commons accepts the authority of Strasbourg in this relatively insubstantial matter, it will thereby accept its jurisdiction over a number of vital matters in the future. The majority of MPs now appreciate that the long-term effects of surrender to the sovereignty of Strasbourg could be dire.

The argument that the House of Commons has freely accepted obligation to accept the authority of the human rights court has worn thin. Even if it was a free agreement by our elected legislators in 1994, it does not represent the wishes of today's House of Commons. When the prisoner votes issue was debated on 10 February 2011, no more than 22 of the 649 MPs supported the Strasbourg judges.

While prisoner voting has brought the underlying conflict between Westminster and Strasbourg to the fore, there is a possibility that equally contentious issues lie ahead. The ramifications of the Kiss case on voting rights of those with mental disabilities have not yet been felt. Unwise obiter dicta of the Strasbourg judges in 2010 about Jewish brit milah (infant male circumcision) are already raising alarm.

There are two ways in which the wishes of the majority of our elected lawmakers may be respected and the UK simultaneously may honour its existing legal agreements. The first, more radical, is to renounce the treaty committing the UK to the jurisdiction of the European court of human rights. The UK is entitled to do this provided it gives six month's notice.

If the UK took this step, it would still be committed to honour the human rights provisions of the Convention since they are incorporated in the Human Rights Act (HRA). Crucially, this change would make it the sole responsibility of UK judges to adjudicate. Parliamentary sovereignty would be restored because the HRA allows parliament to override decisions of the UK judges, whereas the European Convention Treaty does not permit Parliament to override Strasbourg.

It is empty rhetoric to argue that withdrawal from the jurisdiction of the Strasbourg judges would discredit the UK. Not only has Britain an exceptionally good record of compliance with judicial rulings on human rights matters, it would remain committed to the rights set out in the Convention, albeit adjudicated by senior UK judges. Nor are threats that the UK would be forced out of the Council of Europe and the European Union realistic.

However, a second solution would be preferable. Britain could negotiate with the committee of ministers of the Council of Europe to amend the existing treaty. This would allow national parliaments to override Strasbourg decisions on general matters of policy. At first sight this idea may appear to be wholly destructive of the court. On closer reflection, the very opposite could be the result. This is what the Strasbourg judge with whom I have discussed the matter has indicated.

His reasoning is as follows. The greatest problem facing the European court is that some of the countries with the poorest human rights records regularly ignore its judgments. Were countries permitted to override decisions on those rare occasions when their parliaments voted to do so, the expectation would be automatic compliance by governments in all other cases. The overall effect would be increased compliance by the shaky new democracies which were accepted into the Council of Europe following the break-up of the Soviet Union.

The hatred of the Strasbourg judges of which Sir Nicolas Bratza, the outgoing president, has complained does not stem from misreporting. It is a reflection of the widening realisation by our elected politicians that a 47-nation foreign court with far-reaching authority over every British governmental body and over every piece of legislation is incompatible with a democratic system of government.

No credible system of international elections and accountability has been devised. In any case, the House of Commons has made it very clear that it does not wish to hand over its sovereignty.

Were Strasbourg to be so unwise as to impose a mass of small fines on the UK as retaliation for defying its demands on prisoner voting, British hostility would burgeon. Exit from the Strasbourg system would become more likely. By contrast, if the Council of Europe accepts the powerful case for making compliance with the court's rulings subject to national parliaments, the standing of the court and its effectiveness will grow.