The 53rd-ranked Russian outlasted third-ranked Murray 6-4, 4-6, 7-6 (7/4) over two hours and 42 minutes to reach the third round at the ATP and WTA Washington Open.
Murray, the first Washington top seed to lose his first match since Ivan Lendl in 1993, served for the match in the third set and was two points from victory before Gabashvili broke to 5-5 and the Russian later took the final four tie-breaker points to secure the triumph.
Gabashvili, who was 3-22 against prior top-10 foes, hit 30 winners and only made 15 unforced errors while winning 86 percent of first-serve points in making Murray the highest-ranked victim of his career.
"Anytime you beat Andy Murray 7-6 in the third it's something special -- 100 percent it's my best victory," Gabashvili said.
More From This Section
It was a shocking defeat for the 28-year-old Scotsman, who sparked Britain's Davis Cup team past France in July after a semi-final run at Wimbledon.
"Temu served well but I usually back myself to return better than I did," Murray said. "That cost me a lot tonight. Pretty frustrating. I was happy with how I moved and did certain things on the court. There are some things I felt I could improve.