Former United States President Barack Obama said the things people say on social media could splinter society, and it was up to world leaders to make sure that the internet does not propagate such biases.

“One of the dangers of the internet is that people can have entirely different realities, they can be just cocooned in information that reinforces their current biases,” Obama said in an interview with Britain’s Prince Harry, broadcast on BBC radio on Wednesday.

Harry, Queen Elizabeth’s grandson and fifth-in-line to the British throne, was a guest editor on BBC Radio 4’s Today programme on Wednesday.

Obama said social media should promote diverse views, and urged people to move conversations offline to see that many problems were not as simple as they seem in a chatroom.

“Meet in the pub...Meet at a place of worship. Meet in a neighbourhood and get to know each other,” said Obama, adding that it was “harder to be as obnoxious and cruel in person as people can be anonymously on the internet”.

Prince Harry also that said just “liking” something or sharing content doesn’t make a change. “If you really want to make [a] change, you need to look up from your phones and get out in your communities,” he said. “On the social media front, educate or regulate.”

But the interview was not all serious talk. Prince Harry ended it with a rapid fire questionnaire for Obama: “Suits or The Good Wife? Rachel or Monica? Harry or William? The Queen or the Queen?” Obama picked Suits, Rachel and Prince William. In response to the rhetorical last question, he chose the queen.