Dallas had surprising success on the boards against Detroit's imposing front line. The Mavericks finished with 16 offensive rebounds. The Pistons, who came in as the NBA's top team in that department, had only nine.
Detroit star Andre Drummond was in foul trouble all night and finished with only eight points and three rebounds in just under 20 minutes of action.
Josh Smith kept the Pistons in the game for a while and finished with 32 points, his most since signing with Detroit last offseason.
Monta Ellis had 12 points and 13 assists for the Mavericks.
Dallas now leads ninth-place Memphis by two games in the Western Conference playoff race. The Pistons, meanwhile, fell 3 1/2 games behind Atlanta for the final playoff spot in the East.
Dallas led by 13 in the third quarter, and after the Pistons closed within four in the fourth, Nowitzki connected from beyond the arc to give the Mavericks a 96-89 lead. Dallas was able to keep Detroit at arm's length after that.
Ellis scored 10 points in the fourth quarter, and the Mavericks benefited from Drummond's absence throughout the game.
Greg Monroe had 17 points and 17 rebounds for the Pistons, but he had little help on the boards. Smith, for all his scoring, finished with only three rebounds, and he didn't score a point in the final period.
Detroit's Brandon Jennings had only two points and three assists on 1-of-7 shooting, and for a second straight night, the Pistons went mostly with Will Bynum at point guard with the game on the line. Bynum had 17 points and eight assists.
The Mavericks had 31 assists, one night after reaching a season-high 39 in a win at Philadelphia. Ellis had 11 assists in the first half against the Pistons, and Dallas led 64-54 at halftime.
Only Smith - who had 24 points on 11-of-13 shooting in the half - kept Detroit from a bigger deficit. The Pistons were only down 39-36 when Drummond picked up his third foul with 9:03 left in the second quarter. The Mavericks slowly extended the margin after that.
NOTES: Dallas improved to 17-8 against the East this season. ... Carter appeared to be hit in the midsection in the first quarter and grimaced as he came up the court. Then he took a pass and immediately spotted up for a 3-pointer that gave Dallas a 29-25 lead.