CHARLOTTE, N.C. (AP) -- James Gist scored 25 points and hit the clinching free throw with 5.6 seconds left as Maryland avoided a stunning collapse by holding off Charlotte 76-72 on Saturday.
Greivis Vasquez added 17 of his 24 points in the first half for the inconsistent Terrapins (9-6), who won their third straight game since embarrassing home losses to Ohio and American, but nearly blew a 21-point second-half lead.
Charlotte (8-5) twice got the deficit to two in the closing moments, and Leemire Goldwire missed a tying 3-point attempt. Gist then hit 1 of 2 free throws to put it away.
Lamont Mack scored 18 points and Goldwire added 13 on 3-of-17 shooting for the 49ers, who had their two-game winning streak snapped.
In their first true road game of the season, Maryland stormed to a 53-32 lead on Gist's 3-pointer with 15:31 left.
Then the Terrapins began a meltdown that nearly cost them the game. Turnovers, poor shots, foul trouble and defensive breakdowns allowed Charlotte to outscore Maryland 29-11 over the next 10 minutes.
DiJuan Harris' driving layup made it 64-61, leading frustrated coach Gary Williams to call a timeout. Vasquez's 3 and Gist's layup got the lead to 71-63, but Charlotte rallied again, getting the gap down to three on Mack's layup with 2:45 left.
Charlotte got the deficit down to two on Mack's two free throws with 19.2 seconds left. Vasquez then hit one free throw before Goldwire, who shot 2-of-12 from 3, missed another long range shot.
The 49ers rallied despite Goldwire's poor game and 35 percent shooting thanks to a 43-33 rebounding edge and forcing 18 Maryland turnovers.
With only one non-conference game left until starting Atlantic Coast Conference play in earnest, Maryland will face more questions after a horrible second half.
Williams again tinkered with his rotation Saturday in a season where he ordered the nameplates and player pictures in their home locker room removed after the loss to American.
The Terrapins responded with blowout wins at home against Delaware and Savannah State, and carried their solid play early on to Charlotte Bobcats Arena, site of the ACC tournament in March.
Vasquez's first-half scoring spree seemingly put the Terrapins in control.
His three-point play, baseline jumper, 3-pointer and two free throws in a personal 10-0 run put Maryland ahead 32-19.
Vasquez was also busy at the other end shutting down Goldwire, as Charlotte missed seven straight shots and committed five turnovers in going nearly 6 minutes without a field goal.
Eric Hayes' two free throws put the Terrapins ahead 40-25 at halftime, as Goldwire was held to three points on 1-of-6 shooting.
Maryland started the second half on a 13-7 spurt to take a seemingly invincible lead.