The playoff-bound Mavericks were locked in a 71-71 tie in the final minute of the third period but scored the final six points of the quarter and then relied on Carter to fight off the Warriors the rest of the way.
Dallas wrapped up a post-season spot Thursday without playing, clinching the berth when Houston suffered a loss. That allowed the Mavericks to rest some of their key players Friday, with Dirk Nowitzki seeing just 27 minutes of action.
Brandan Wright came off the bench to score 17 points while making 8-of-9 from the field. Nowitzki and Delonte West both had 16.
Dallas is in the sixth spot in the Western Conference with two games to go and is looking at a possible first-round playoff matchup with the Los Angeles Lakers. The Mavericks swept the Lakers in four games during last year's playoffs, but lost all four regular-season meetings with Los Angeles this year.
Golden State, which has dropped seven in a row, was led by 26 points from Klay Thompson.