(SportsNetwork.com) - The San Antonio Spurs are peaking at the right time and they'll try to keep the momentum going Wednesday night when they visit the Amway Center to face the Orlando Magic.

The defending champs have won four in a row and are poised to clinch a playoff berth. They are a half-game out of the fifth seed, currently occupied by the Los Angeles Clippers.

A win on Wednesday gets the Spurs in the postseason.

San Antonio inched closer to the playoffs with a 95-81 win over the Miami Heat Tuesday in South Beach.

Kawhi Leonard posted 22 points and nine rebounds with a full line. Leonard added three assists, four steals and two blocks.

Tim Duncan had 12 points and 11 rebounds and Tony Parker scored 16 points for the Spurs, who have won three straight regular-season meetings with Miami after dropping the previous five.

Cory Joseph only scored seven points, but it was his defense and intensity off the bench in the second half that helped the Spurs pull away. Joseph matched a career-high with four steals.

"We know we can't win a championship without defense," said Parker. "Our defense has been great."

The Spurs ended any hopes of a Heat comeback with a 12-2 spurt to open the fourth. Joseph and Leonard both came up with steals and assisted on each other's transition baskets during the flurry.

San Antonio returns home on Friday against the Denver Nuggets, but the big matchup comes Sunday when the Western Conference-leading Golden State Warriors come to town.

The Magic have lost three in a row and are 1-9 over their last 10.

Orlando opened their five-game homestand with a win over the Portland Trail Blazers, but fell to the Nuggets, Atlanta Hawks and Detroit Pistons. The stay ends Wednesday.

The Magic fell to the Pistons on Friday, 111-97.

Orlando lost despite a 20-point, 14-rebound effort from Nikola Vucevic. Tobias Harris paced all five Orlando starters in double figures with 21 points and Elfrid Payton contributed 14 points and 13 assists.

Sloppy play hurt Orlando all night. The Magic shot 52.4 percent, but 17 turnovers led to 23 Detroit points.

"You've got to take care of the ball," said interim Magic coach James Borrego. "You can't get casual."

Detroit led by as many as 17 in the fourth. Reggie Jackson's jumper put the Pistons up 108-91, and his assist on Joel Anthony's layup with 1 1/2 minutes remaining secured his second triple-double of the season.

The Spurs beat the Magic by seven in San Antonio on Feb. 4.