They spoke the same language and consulted each other on all important matters of state. So close was the bond that he was the one unleashed to deal with political opponents while the President concentrated on running the government.
In most cases, ministers had to run DP Gachagua's instructions through the Head of Public Service boss Felix Koskei or State House just to be sure that the President had approved them.
But now, with the arrival of the ODM party, even though there is no formal agreement between the President's UDA party and Mr Raila Odinga's outfit, a third centre of power has been added to the mix.
"This is the problem of keeping some of these things confidential...," he said after receiving the list from State House spokesman Hussein Mohamed as he explained what looked like a hiccup in his address.
With this development, DP Gachagua's stranglehold on the corridors of power has further diminished. He will now have to sit in the same Cabinet with ministers loyal to Mr Odinga, a man he has in the past vowed not to let near power.
"Leave the job of guarding the President to me. If anyone tries to approach State House, I have set traps on every possible path they could take. There is no way they can get through. So, there's nothing for you to worry about," he said before the honeymoon ended.
In context, he was saying that Kenya's Kwanza government would not agree to go down the 'handshake' route as compared to the regime it inherited when the then president embraced Mr Odinga in a loose coalition.
It is a script lifted from 2018 when the rapprochement between President Uhuru Kenyatta and Mr Odinga, the common denominator in this playbook, displaced Dr Ruto from the centre of power.
The ousting was so bitter that the then-deputy president immediately launched his presidential campaign, knowing that the duo would not support his bid. Mr Gachagua too must be keeping a close eye on events. Some of his supporters want him to go for the big seat in the next elections.
In fact, his handlers say he will now be aggressively courting Mr Kenyatta and the remaining Azimio principals to work out a working formula ahead of the 2027 polls.
"Even our son Uhuru Kenyatta should come out and we should unite. Is that okay? Do you have a problem with anybody? The election period is over and we should unite as one house and love one another. The moment we allow ourselves to be divided, we are doomed. Do you want us to unite?" Mr Gachagua said in a recent charm offensive to the retired president, for whom he had no kind words in the run-up to the last elections.
One of his close allies told Nation.Africa that he is considering teaming up with Wiper leader Musyoka and will use the backing of the wealthy Kenyatta empire to give Mr Ruto an upset in the next polls.
With the country's politics organised along tribal enclaves, a solid Kamba and Kikuyu voting bloc - provided the duo can rally their communities behind them - can give the incumbent a run for his money.
On the other hand, Mr Odinga's entry offers Mr Ruto some compensation as he brings with him the entire Luo bloc and with Mr Mudavadi, Speaker Moses Wetang'ula, who remains at Kenya Kwanza, the populous Luhya vote.
"It is embarrassing that it took protests, deaths and destruction of property for the president to realise the extent of the problem. The NIS has embarrassed the president," said DP.
Rarely do those in power take on those in charge of such strategic positions. While Mr Haji didn't react, as spies don't conduct their business in public, those around the president felt that he was the real target of the missile, not Mr Haji.
His shareholder gospel government also rubbed many the wrong way, especially and rightly in the Azimio zones, his opponents in the last elections.
In the end, observers say, the shaky relationship between the president and his deputy necessitated the handshake with Mr Odinga. They say the president has been fighting on two fronts, opposition from within his own government and a tide of Gen-Zs who have vowed to sweep him out of power, so bringing in ODM troops is meant to keep his ship from running aground. Time will tell if the experiment works.