Demi Lovato knows a thing or two about going to rehab, so when Selena Gomez faced troubles of her own, the singer urged her friend to get help.

Lovato, who spent time in rehab in 2010 and 2011 for physical and mental issues, encouraged Gomez to acknowledge her problems and check herself into rehab.

"Demi helped her find the strength to do it," an insider said. "Demi told her it's OK to be honest about having a problem."

Lovato and Gomez have been friends since childhood, and though they had a falling-out, they say they're stronger than ever.

"They've really bonded over their issues," the source said.