If not for a chance encounter with a famous comedian and animal activist, actress Meghan Markle may never have discovered one of the great loves of her life. No, we're not talking about Prince Harry, who recently popped the question to the former "Suits" star, but Bogart, a Labrador/shepherd mix that Markle rescued from an animal shelter.

The 36-year-old said she was visiting a shelter a few years ago when Ellen DeGeneres and her wife, Portia de Rossi, walked in.

"Now, I don't know her, but Ellen goes 'Is that your dog?' And I said, 'No,' and she's like, 'You have to take that dog.’ And I said, 'Well, I'm deciding.' And she's like, 'Rescue the dog!'" Markle told Best Health. "It's sort of like if Oprah tells you to do something. I'm sitting there holding him and she's like 'Have you thought of a name for him yet?' And I said, 'Well, I think I'd name him Bogart,' and she's like 'You're taking the dog home.'"

Markle took Ellen's advice to heart, adopting Bogart and later a second dog, a beagle named Guy. The two pups quickly became frequent stars of the actress' Instagram page.

My loves #adoptdontshop #happysunday

A post shared by Meghan Markle (@meghanmarkle) on

Oh, my boys. This pic says it all. Bogart & Guy. 😂 #adoptdontshop #thelookonbogartsface

A post shared by Meghan Markle (@meghanmarkle) on

Me and my guy. Good to be home. #snuggles #homesweethome #adoptdontshop

A post shared by Meghan Markle (@meghanmarkle) on

Since her courtship with Prince Harry, Markle has been splitting time between the U.K. and her home in Toronto, Canada. Her dogs, however, have never been far from her mind.

"I have two dogs that I've had for quite a long time, both my rescue pups," she said in a recent interview with the BBC. "And one is now staying with very close friends and my other little guy is — yes he's in the UK, he's been here for a while."

All dressed up, with nowhere to go. Oh hey, Guy. #adoptdontshop #yesheneedsasweateritsFREEZING #puppylove

A post shared by Meghan Markle (@meghanmarkle) on

According to Prince Harry, Markle's love of animals made a big first impression on Queen Elizabeth, who has a famous entourage of corgis.

"I've spent the last 33 years being barked at; this one walks in, absolutely nothing …" Harry joked.

Markle, who plans to retire from acting, is slated to become the fourth patron of The Royal Foundation, a charitable organization created by The Duke and Duchess of Cambridge and Prince Harry. Since 2009, the foundation has supported dozens of charities focused on everything from animal conservation to children's services.

"My life shifts from refugee camps to red carpets," Markle said while addressing the U.N. Women's Conference in 2015. "I choose them both because these worlds can, in fact, coexist . . . I've never wanted to be a lady who lunches — I've always wanted to be a woman who works. And this type of work is what feeds my soul and fuels my purpose."

Michael d'Estries ( @michaeldestries ) covers science, technology, art, and the beautiful, unusual corners of our incredible world.