Defending world champion Ding, who enters Wednesday's final as the one to beat, defeated Feng Tianwei of Singapore 4-2. Li will be a decided underdog after defeating Kasumi Ishikawa of Japan 4-1.
So another gold medal is guaranteed for China in its national pastime, and about 500 million fans at home may be watching the singles showdown on TV.
China dominates this sport like no other. It has won 20 of 24 gold medals since pingpong was introduced into the 1988 Olympics, and it has won all six gold medals in women's singles.
"This represents a new generation of table tennis in China," Li said, talking about No. 7.
Ding and Li are the fresh faces of the women's game, and they step into territory occupied by national icons. Zhang Yining took four gold medals in the last two Olympics. Wang Nan won hers in three Olympics — 2000, 2004 and 2008. And Deng Yaping started the string with four in 1992 and 1996.
"I'm not going to feel pressure because the gold medal is already guaranteed for our team," said Li, who is known in China as "Ms. No. 2."
Ding has won six of 10 official matches against Li, and defeated her in last year's world championship final.
"I will not be concerned by the underdog name," Li said.
Ding and Li are opposites.
The 22-year-old Ding is left-handed, outgoing and likes to talk. The 24-year-old Li is more reserved and cautious, and plays from the right side. Both are attackers with lots of topspin and looping shots. Ding, in particular, is an acrobat who nearly drops to her knees to hit shots from strange angles.
"We are quite close," Ding said. "It's good the Chinese people will have some much interest in us. But I will just try to concentrate. Anyway, the outcome is unpredictable."
One thing you can bet on — the 6,000-seat venue will be packed and deafening with chants of "Jai Yo, Jai Yo, Jai Yo." That's the Mandarin equivalent of "Let's Go," though it literally means "Add Oil."
Li said she expected to talk with Ding before the final, but not too much more. No plans to practice together or dine together.
"It is just going to be a normal conversation because this is not the first time we have met in a final," Li said.
Ding was pushed in her semifinal against Feng, who was born in China but emigrated to play in Singapore. Ding won 11-7, 11-4, 9-11, 12-10, 6-11, 11-6.
Ding has won 12 of 13 matches against Feng.
"I tried, but at least it's over," Feng said. "Ding is the top player in the world and I am happy how I played considering this."
The 19-year-old Ishikawa is trying to make history in Japan, which has a strong tradition in table tennis but has yet to win an Olympic medal of any kind in the sport.
A bronze would feel like gold.
"I didn't feel under too much stress," Ishikawa said of the match against Li. "I could see Li was very tense, but she was still powerful enough to beat me."
In two late men's matches on Tuesday, Chuang-Chih-Yuan of Taiwan and Dimitrij Ovtcharov reached the semifinals.
Chuang, who reached the quarterfinals in 2004, pulverized Adrian Crisan of Romania 11-3, 11-4, 11-4, 11-5. Ovtcharov defeated Michael Maze of Denmark 4-3.
It was a bitter-sweet victory. Chuang said Crisan is his best friend in the game.
"But this is sport and I was very sorry yesterday when I knew I would have to play against him. It was a very bad feeling. ... It was like you have to kill your brother."
In Wednesday's two quarterfinals, Zhang Jike of China plays Jiang Tianyi of Hong Kong, and Seiya Kishikawa of Japan goes against Wang Hao of China.
Follow Stephen Wade at https://twitter.com/StephenWadeAP