A split in the UK Coalition emerged last night over the tough sentences being handed down to those convicted of criminal behaviour in the recent riots across England with Conservatives welcoming them but Liberal Democrats suggesting some have been excessive.

David Cameron praised the courts after Jordan Blackshaw, 20, and Perry Sutcliffe-Keenan, 22, were jailed for four years for setting up Facebook pages that encouraged people to riot.

“What happened on our streets was absolutely appalling behaviour and to send a very clear message that it’s wrong and won’t be tolerated is what the criminal justice system should be doing,” declared the Prime Minister.

“They decided in that court to send a tough sentence, send a tough message and it’s very good that courts are able to do that,” he added.

Blackshaw’s solicitor, Chris Johnson, said last night his family was “shocked and upset” at the sentence and said he had been instructed to appeal it.

In a separate case, a 17-year-old student who used Facebook to urge people to riot was spared a jail sentence and instead was given a year-long rehabilitation order and banned from social networking.

Simon Hughes, the Liberal Democrat deputy leader, admitted there were “two strands of political opinion” in the Lib-Con Coalition. “The people who have criminal offences can expect no mercy,” he insisted. “But I hope the courts will look more sympathetically on a youngster who has never had a criminal offence and may have been swept up into the system.”

His backbench colleague Tom Brake condemned the jailing of people for stealing single, low-cost items, saying: “We are putting petty offenders in colleges of crime with no prospect of rehabilitation or re-education.”

However, former party leader Sir Menzies Campbell argued politicians should steer clear of commenting directly on sentences.

He said: “With all due deference to the Prime Minister, politicians should not be either cheering nor booing in the matter of sentencing.

“It is an important part of our constitutional principles that political influence is not directed at the judicial system.”

In contrast, Eric Pickles, the Tory Communities Secretary in England, said: “We need to understand that people for a while thought that this was a crime without consequence. We cannot have people being frightened in their beds, frightened in their own homes for their public safety.”

Yet Lord Carlile, the LibDem peer, took ministers to task for appearing to influence the courts. The former independent adviser to the UK Government on counter-terrorism said: “I don’t think it’s helpful for ministers to appear to be giving a steer to judges.

“The judges in criminal courts are mostly extremely experienced and well capable of making the decisions themselves. Ministers should focus on securing the safety of the public,” added the former MP.

However, the Ministry of Justice stressed the magistrates and judges were independent of Government. “Their sentencing decisions are based on the individual circumstances of each case and offender,” explained a departmental spokesman.

“That is why different offenders may be given different sentences for what might appear to be similar crimes. To provide a consistent base for these decisions an independent body of experts, the Sentencing Council, set guidelines for them to use.”

Nonetheless, human rights campaigners and lawyers warned against “knee-jerk” reactions to the riots that for days raged across several English cities.

John Cooper, QC, a leading criminal barrister, warned that judges and magistrates had a duty “not to be influenced by angry Britain” and branded some of the sentences handed down already as “disproportionate and somewhat hysterical”.