Two-time French Open champion Swiatek came from behind to defeat sixth-seed Sabalenka 3-6, 6-1, 6-4 at Arthur Ashe Stadium and reach her maiden US Open final.
Sabalenka had been chasing the first Grand Slam final of her career after just missing out with semi-final defeats at Wimbledon and the US Open last year.
But the 24-year-old from Belarus suffered a late collapse while leading in the third set as Swiatek edged victory.
Polish star Swiatek said an emergency bathroom break after losing the first set had been crucial.
"I kind of needed to go," Swiatek said. "For sure I felt lighter. I'm sorry -- that's disgusting," the 21-year-old added.
"I tried to use that time to think about what to change because I remember when I was younger all I would do in the bathroom between sets after I lost was cry.
"But this time I could think about what to change and actually problem solve."
Sabalenka looked well placed to break her final duck as she swept into an early lead against the top seed.
The hard-hitting Sabalenka broke Swiatek three times in the opening set, rattling her opponent's shaky service game and stretching her with an array of powerful groundstrokes.
But Swiatek looked rejuvenated after her bathroom break following the first set and came out for the second all guns blazing.
She broke Sabalenka to love in the opening game and then held twice for a 3-1 lead.
She sealed a further break with a backhand cross-court return of serve to open up a 4-1 advantage as Sabalenka struggled to cope with the change in tempo.
She was broken again in the seventh game, Swiatek levelling the match after Sabalenka fluffed an easy volley at the net on set point.
Nevertheless Sabalenka appeared to have stopped the bleeding in the third set.
She broke Swiatek in the opening game and then broke again for a 3-2 lead after Swiatek had broken back.
She held serve for a 4-2 lead and the momentum seemed to be with her.
But Sabalenka's game disintegrated from that point on. Swiatek broke her to love to make it 4-4 and then held for a 5-4 lead.
Sabalenka was overrun in the 10th game as Swiatek raced into a 0-40 lead to move to triple matchpoint.
Sabalenka held off the first with a forehand volley at the net, but her 44th unforced error on the next point sealed her fate.