The world champion struggled to contain his powerful Indonesian opponent, who was finding both corners of the court in the first half of the match.
But the top seed dug deep to fight back from 16-11 behind in the second game to force a decider.
Momota trailed again in the last game as Ginting sought a third straight upset win in as many days.
But the left-hander used a combination of improvisation and guile to craft a run of 13 points in 14 to seal a stunning victory with a disguised drop shot on his first match point.
“I felt my opponent played better than me today but I was able to capitalise when he got tired,” Momota, who also won the Singapore title in 2015, told reporters.
“He tried to push a little too hard in the second game but I kept telling myself to stay patient and never give up.”
In the women’s singles final, Tai Tzu-ying claimed her second Singapore Open title with a 21-19 21-15 victory over Japan’s Nozomi Okuhara.
The Taiwanese world number one backed up last week’s Malaysia Open triumph with a display full of speed, skill and spontaneity to outfox the world number three in 40 minutes.
The result improved her head-to-head record against the energetic Okuhara to 5-4.
The match soon settled into a rhythm with Tai using deft drop shots and disguised smashes to keep Okuhara moving, while her opponent went high and long in an attempt to pin the top seed to the back of the court.
There was little to separate them in the early exchanges but Tai managed to string together runs of points in the later stages of both games to pull clear, the 24-year-old completing the win with a crosscourt smash.
“Okuhara is a good opponent, she’s very durable, so I was prepared for a long match,” Tai said. “I am playing well right now but it’s important to stay injury-free with the Tokyo Olympics coming up next year.”
In other finals, Thailand’s Dechapol Puavaranukroh and Sapsiree Taerattanachai eased to a 21-14 21-6 victory over Malaysia’s Tan Kian Meng and Lai Pei Jing in the mixed doubles.
Japan’s Mayu Matsumoto and Wakana Nagahara beat South Korea’s Kim Hye-jeong and Kong Hee-yong 21-17 22-20 in the women’s doubles.
There was further success for Japan in the men’s doubles as Takeshi Kamura and Keigo Sonoda outlasted Indonesia’s Mohammad Ahsan and Hendra Setiawan 21-13 19-21 21-17.
Download our app and read this and other great stories on the move. Available for Android and iOS.