The justice secretary, David Gauke, has launched an impassioned attack on “populist politicians” who deceive the public by telling them what they think they want to hear.

In a speech to the annual judges’ dinner in the City of London on Wednesday, Gauke, a forthright opponent of a no-deal Brexit, anticipated his imminent removal from office and contrasted the fact-finding diligence of the judiciary with his political colleagues who “pour poison into our national conversation”.

Adopting gallows humour, the Conservative MP who has survived no-confidence votes in his south-west Hertfordshire constituency, began by telling his legal audience that he was “a veteran” compared with recent justice secretaries, who have not lasted long in the job.

“Indeed, I am the first lord chancellor in a while to have served long enough to deliver two of these speeches,” Gauke said at the Mansion House dinner.

“It is true that my predecessor but two, Michael Gove, made it to his second speech but he left the government one week later [in July 2016] when a new prime minister, with whom he did not see eye to eye [Theresa May], took office. How times have changed. I might only have three weeks.”

In remarks that will be viewed as a veiled attack on the Conservative leadership frontrunner Boris Johnson, the justice secretary said: “There is no doubt in my mind that the forces of populism are much stronger in this country and internationally than has been the case for some time.

“A willingness by politicians to say what they think the public want to hear, and a willingness by large parts of the public to believe what they are told by populist politicians, has led to a deterioration in our public discourse.

“This has contributed to a growing distrust of our institutions – whether that be parliament, the civil service, the mainstream media or the judiciary.”

A dangerous gulf is emerging, he said, between the people and the institutions that serve them. Such institutions – including the legal system and the judiciary – provide the “kind of confidence and predictability that underpins our success as a society”.

Gauke continued: “Rather than recognising the challenges of a fast-changing society require sometimes complex responses, that we live in a world of trade-offs, that easy answers are usually false answers, we have seen the rise of the simplifiers.

“Those grappling with complex problems are not viewed as public servants but as engaged in a conspiracy to seek to frustrate the will of the public. They are ‘enemies of the people’.”

Gauke’s jibe refers to the Daily Mail headline in 2016 attacking the judges who found in favour of only parliament having the power to trigger article 50 and the UK’s departure from the EU.

He explained: “In deploying this sort of language, we go to war with truth. We pour poison into our national conversation. But language really matters in our discourse.

“Our judiciary has a reputation for intellectual rigour, careful consideration of the arguments, and a serious-minded determination to each decision based on what is right and not necessarily what is superficially popular. I am not sure that all politicians have the same reputation.”

Politics, the justice secretary said, should be about finding and embracing practical solutions to society’s problems “not as we imagine or represent it to be. We must face facts. I have made that my guiding principle in office.”