Pierria Henry scored 17 points, including two late free throws, and the 49ers hung on for a 71-67 victory that ended the Bulldogs' home winning streak.
Chris Braswell and Willie Clayton each had 11 points for the 49ers, who ended a two-game skid.
Rotnei Clarke scored 18 and Roosevelt Jones had 17 points and nine rebounds to lead the Bulldogs (20-5, 7-3 Atlantic 10), who hadn't lost at home in 12 games.
"I think the right team won," Butler coach Brad Stevens said. "It probably would have been a disservice if Butler would have won."
|More on college basketball|
The 49ers (18-6, 6-4) went on a 7-1 run late in the game and then withstood a late charge by the Bulldogs that got them within a point.
"Does anybody have a stretcher?" Charlotte coach Alan Major said. "I may need to be carried out of here after that one."
It was certainly a nice homecoming for the coach who grew up in Indianapolis and later attended Purdue, about an hour northwest of the city.
After the 49ers built a 10-point lead, the Bulldogs went on an 8-2 run.
Clarke hit a 3-pointer and the 49ers missed a shot. Kellen Dunham made two free throws to make it 60-55 with 2:20 left.
E. Victor Nickerson hit a jumper and then Clarke made a 3-pointer to make it 62-58 with 1:31 left.
Clarke hit a 3 with 22.6 seconds left to make it 66-61 and then Denzel Ingram made one of two from the line.
"They just hit tough shots," Nickerson said. "It was a big win. That's a good team and we're a good team."
Clarke was fouled on a 3-point attempt and hit all three free throws to make it 67-64, but Henry made one of two from the line.
Clarke hit a deep 3 with 7 seconds left to pull Butler to 68-67. Henry made one of two from the line and the Bulldogs turned the ball over on an inbounds pass.
"It was going to Rotnei," Stevens said. "But it didn't ever get to the point where he could get the ball."
At that point, the 49ers didn't know what Butler was going to do.
"I didn't know what to expect," Major said. "I was expecting Clarke in some form or fashion, but sometimes when you're expecting that, as a coach, you think they're going the other direction."
Butler shot 39 percent and turned the ball over 11 times. At halftime, the Bulldogs were just 2 of 11 from 3-point range.
Butler turned the ball over right away to start the second half and Ingram scored to give the 49ers a 31-27 lead.
Butler's Erik Fromm, who made his first start of the season, scored on a putback and then Henry was fouled on a shot and converted the three-point play to give the 49ers a 34-29 lead.
Jones scored for Butler and Clayton for Charlotte before Fromm hit a 3 to make it 36-34.
Clayton scored again and Fromm hit another 3-pointer to make it 38-37 with 16:20 left, but Henry answered with a 3-pointer of his own to give the 49ers a 41-37 lead.
Clark scored for the 49ers and Dunham hit a 3 to make it 43-40.
Later, Braswell made two free throws to give the 49ers a five-point lead. Then the 49ers went on a 7-2 run.
Fromm hit a 3-pointer to make it 51-47, but Nickerson made two free throws to extend the lead again.
Butler played without Andrew Smith, who was out with an abdominal injury sustained in a 59-56 victory over George Washington last week. He will also miss Saturday's game at Fordham.