It was the start of a big night for a Chinese swimming team that is developing into a major power.
Shortly after Sun won the 400-meter freestyle by a large margin over defending champion Park Tae-hwan, 16-year-old teammate Ye Shiwen announced her arrival on swimming's greatest stage with a world record in the grueling 400 individual medley.
Ye celebrated with teammate Li Xuanxu, who was in the next lane and took bronze.
Sun had already established himself by taking down Grant Hackett's 11-year-old world record in the marathon-like 1,500 free before a home crowd at last year's world championships in Shanghai, but he had never won an Olympic medal.
"I was so eager and impatient to go on the podium," said Sun, shedding tears after cooling down from his victory celebration. "Today if I cry it's really because I worked hard for one year, or even more. I get up very early and worked very hard. This is a reward for me and my coach, who is not well. After I return he will go through surgery. My parents came. They are really great parents, they gave me so much."
Sun trains under Hackett's former coach, Denis Cotterell.
Park was temporarily disqualified for a false start in morning heats, but was then reinstated following an appeal.
"With him in the final I think this is a good achievement," Sun said
Ye won the 200 IM in Shanghai and wasn't among the pre-race favourites for the 400.
"I'm still young," Ye said. "After training I'm sure I'll be even better."
Sun finished nearly two seconds ahead of Park, while Ye was nearly three seconds ahead of silver medallist Elizabeth Beisel of the United States.
"This is a big step for Chinese swimming," Ye said.
Local hope Hannah Miley of Britain settled for fifth and was marveling at her Chinese rival's speed.
"That was very, very fast, and it'll be intriguing to look at the analysis and stuff because there are a lot of things that they've obviously taken from us and learned from," Miley said. "And, for us, it's an opportunity to learn from them."
Peter Vanderkaay, the American who took bronze behind Sun and Park, was also complementary.
"Obviously they're off to a great start," Vanderkaay said. "Sun Yang had a great swim and I can just tip my hat to him. They're swimming great and hopefully we can match them as the meet progresses."