Gauff has been in brilliant form on the clay and had cruised through to her first slam quarter-final but she was unable to take any of five set points in the opening set and faded badly afterwards to lose 7-6 (6) 6-3.
The 17-year-old led 3-0 and 5-3 in the opening set, as well as 6-4 in the tie-break, but each time Krejcikova battled back and she pounced on her first set point.
Both women were on nine-match winning streaks having won titles the week before the tournament, but the outcome soon looked inevitable.
The disappointment for Gauff was evident as she made a poor start to the second set and she was unable to recover, smashing her racket forcefully on the court after a double fault left her 4-0 behind.
Krejcikova, better known as a doubles player and also through to her first slam quarter-final in singles, quietly went about her business at the other end, showing no sign of nerves as the finish line approached.
Gauff battled to at least get on the scoreboard and Krejcikova did start to feel the occasion, seeing three match points come and go at 5-1, the last an open-court backhand that she put wide.
When Gauff saved two more match points and held for 3-5, it seemed like a dramatic turnaround might be on the cards, but Krejcikova took her sixth chance, holding her arms aloft.
The 25-year-old said: "I never really imagined that I'm going to be standing here one day, standing on this court, especially singles. Being able to win, already for me this is something I've never dreamed of."