Within eight hours, the post had been liked more than 2.7 million times. Barker replied with a black heart emoji and also re-shared the same image.
The eldest of the famous sisters, Kardashian has three children with her ex-partner Scott Disick.
Barker, an acclaimed drummer and music producer, is a father of two who has been married twice, including to former Miss USA Shanna Moakler.
Kardashian is soon set to appear on screens in the 20th and final series of her family’s reality TV show, which airs in the US in March.
More from Kardashians
A trailer for the final season of Keeping Up With The Kardashians shows her and Disick asleep together on a sofa, leading her half-sister Kendall Jenner to say they are “made for each other, they’re supposed to be together”.
Making the announcement about the show ending in September 2020, Kim Kardashian said: “It is with heavy hearts that we’ve made the difficult decision as a family to say goodbye to Keeping Up With The Kardashians.
“After what will be 14 years, 20 seasons, hundreds of episodes and numerous spin-off shows, we are beyond grateful to all of you who’ve watched us for all of these years – through the good times, the bad times, the happiness, the tears, and the many relationships and children.
“We’ll forever cherish the wonderful memories and countless people we’ve met along the way.”