Dirk Nowitzki scored 23 points, grabbed 10 rebounds and the Dallas Mavericks used a big fourth-quarter run to get a 95-85 victory over the Memphis Grizzlies on Wednesday night.

Shawn Marion scored 10 of his 16 points when the Mavericks went ahead with a 21-4 run over a 7-minute span in the fourth quarter to take control.

It was the first of two games in four days between the teams that are in a virtual tie for fifth place in the Western Conference standings. They play again Saturday in Memphis, a night after both play different teams.

Dallas (31-24) had dropped to sixth place behind Memphis after a 95-74 loss Monday night at home against the fourth-place Los Angeles Clippers.

The Grizzlies (30-23) had won five of six games, including road games against division leaders Oklahoma City and the Los Angeles Lakers.

Before playing again, Memphis is at Miami on Friday, when Dallas hosts Portland.

O.J. Mayo had 17 points to lead Memphis, which had balanced scoring as seven players scored at least eight points.

Memphis had a 73-68 lead after Quincy Pondexter's three-point play with 10 minutes left. He moved between Nowitzki and Lamar Odom to grab an offensive rebound and was fouled making the putback shot. He then added the free throw.

Jason Terry's long jumper started the game-turning run and his inbound pass to Marion for a strong layup got the Mavericks within one point.

After Gilbert Arenas came up short on a shot, he fouled Marion on the other end. Marion hit both free throws for a 74-73 lead with 8 minutes left, butting the Mavericks ahead to stay.

Arenas then had a shot blocked by Terry, and Nowitzki made two free throws before Marion's layup for a 10-0 Dallas spurt.

Mayo, who scored nine of his points in the fourth quarter, ended the Dallas run with a driving layup.

The Grizzlies were within 80-77 after two free throws by Mayo. But Nowitzki responded with a 3-pointer and Terry had a steal that led to a layup by Marion, who ended the 21-4 spurt with a breakaway slam dunk with 3 minutes left.

Terry finished with 15 points while West had 14 on 6-of-7 shooting. Ian Mahinmi had 10 rebounds.

Mike Conley had 11 points for Memphis. Marc Gasol had 10 points and 10 rebounds.

Memphis led 46-36 when Conley made a 21-foot jumper with 3:24 left in the first half before Dallas cut its largest deficit with a 9-1 run.

Odom, back after missing Monday night's game with a stomach illness, made a short turnaround hook shot that finally dropped after rattling around the rim.

West then had a pair of long jumpers before blocking a shot. That led to a putback layup by Nowitzki that got Dallas within 47-45 with a minute left.

After Nowitzki pushed through Mayo while Rudy Gay tried to swat the ball away to make a basket, the Mavericks' All-Star head-butted the ball after it went through the hoop and shouted out in frustration.

Gay hit a 19-foot turnaround in the final second for a 51-47 halftime lead.

NOTES: Memphis G Tony Allen left the game with 5:20 left after taking a hard foul from Brendan Haywood. Allen remained in a heap on the floor, dripping blood and leaving with a towel over his mouth. ... Terry's only 3-pointer was the 1,760th of his career, matching Peja Stojakovic for fifth on the NBA career list. .. Dallas G Jason Kidd (strained right groin) missed the second game in a row, and is expected to miss at least two more games. ... The Grizzlies played the fifth of seven games in nine days.