“To be role models, or the role models, that each of you are takes strength and it takes courage,” he said.
“When I talk to my son Archie about what he wants to be when he grows up, some days it’s an astronaut, other days it’s a pilot – a helicopter pilot, obviously. Or Kwazii from Octonauts – if you’re laughing then you’ve seen that.
“But what I remind him is that, no matter what you want to be when you grow up, it’s your character that matters most, and nothing would make his mum and me prouder than to see him have the character of what we see before us today.”
Harry paid tribute to the Ukrainian team at the Games as did Meghan who introduced him.
She added: “I could not love and respect him more, and I know you all feel the same.”
The ceremony began with the arrival of 17 national teams, parading to music from the Dutch Royal Military Band.
Earlier, Harry, 37, and Meghan, 40, took part in the Land Rover Driving Challenge where they rode in two mini Land Rovers driven by children.
The antics were captured by a camera crew from Netflix.
The couple have a multi-million pound deal with the streaming giant and are making a documentary about the games.