The American had earlier called Linz "my little lucky place" and its charm held for the teenager through the final despite a late wobble; after racing to a 5-0 lead in the third set, Gauff dropped two games to Ostapenko before closing out the match.
Gauff entered the tournament as a lucky loser, replacing injured sixth seed Maria Sakkari, having initially failed to make the main draw after suffering a straight-sets defeat to Germany's Tamara Korpatsch in qualifying.
Her second-round win against Kateryna Kozlova earlier in the week secured her a place in the top 100 of the women's rankings and a first WTA tour quarterfinal, from which the teenager emerged victorious after seeing off top seed and world No. 8 Kiki Bertens in straight sets.
Gauff's first tour semifinal led to her first final thanks to a win over Andrea Petkovic of Germany, again in straight sets.
"I'm still overwhelmed and shocked," Gauff said after her victory on Sunday.
"I guess it's crazy to say it's my first WTA title.
"This was definitely not on the calendar at the beginning of the year, because I didn't think I'd have a chance to get in, and now I'm the champion, so it's crazy.
"It's just literally insane that I got in as a lucky loser and now I'm the champion. My dad told me when I got in, before the first main-draw match: 'You can't lose twice in the same tournament!' I'm sure he never thought it would come this far, to being the champion, but I guess he was right."