Updated

All-Star game MVP Melky Cabrera was suspended for 50 games without pay Wednesday after the Giants outfielder tested positive for testosterone, a big loss for San Francisco as it fights for a playoff berth.

Major League Baseball said Cabrera tested positive for the banned performance-enhancing substance in violation of the drug agreement between owners and the players' association.

His penalty was the first for a high-profile player since Ryan Braun's penalty was overturned by an arbitrator last winter, which led to revisions in the drug agreement to better define procedures for handling the urine samples.

"My positive test was the result of my use of a substance I should not have used," Cabrera said in a statement released by the union. "I accept my suspension under the Joint Drug Program and I will try to move on with my life. I am deeply sorry for my mistake and I apologize to my teammates, to the San Francisco Giants organization and to the fans for letting them down."

Cabrera is batting .346 with 11 home runs and 60 RBIs in his first season with San Francisco and is five hits shy of 1,000 in his big league career. Flashing bright orange spikes, he singled and hit a two-run homer last month in the National League's 8-0 All-Star win, which secured homefield advantage for the World Series.

He will miss the final 45 games of the regular season and serve the remainder of the suspension at the start of next season or during the postseason, depending on whether the Giants make the playoffs and how far they advance.

"We were extremely disappointed," the Giants said. "We fully support Major League Baseball's policy and its efforts to eliminate performance enhancing drugs from our game."

If the Giants wanted him to become active in the middle of a playoff series, they would have to play a man short from the start of the series until the suspension ends because rosters can't be altered in mid-series.

Cabrera became the second Giants player to receive a drug suspension this season. Reliever Guillermo Mota was penalized for 100 games in May, becoming just the third major league player disciplined twice for positive drug tests. Mota is eligible to return Aug. 28, barring rainouts, and began a minor league rehabilitation assignment Tuesday with the Giants' rookie team in Arizona.

There have been four suspensions in the major league drug program this year, with Philadelphia infielder Freddy Galvis and free agent outfielder Marlon Byrd also suspended 50 games apiece. There have been 70 suspensions under the minor league drug program.

In mid-May, MLB and the players' union agreed to drop the 100-game suspension imposed on Colorado Rockies catcher Eliezer Alfonzo for a positive drug test because of the same procedural issues that came up in the case of Braun, the Milwaukee outdfielder who is the reigning NL MVP. Alfonzo missed 48 games -- the final 15 of last season and the first 33 of this year.

Braun's 50-game suspension for a positive drug test was overturned in February by arbitrator Shyam Das after Braun's lawyers argued his urine sample was not handled in the manner specified by baseball's drug agreement. Das, who had been baseball's permanent arbitrator since 1999, was fired this spring.

In December 2011, slugger Manny Ramirez received a 50-game suspension for a second positive drug test. The 12-time All-Star signed a one-year minor league contract with the Oakland Athletics on Feb. 20, but was released in June per his request while playing for Triple-A Sacramento before even reaching the big leagues with the A's.

Ramirez retired from the Tampa Bay Rays last season rather than serve a 100-game suspension for a second failed drug test. The penalty was cut to 50 games because he sat out nearly all of last season.

The 28-year-old Cabrera, who became a marketing phenomenon this year with nicknames like "Got Melk?" "Melk Man" and "Melky Way," produced a 51-hit month in May. Cabrera batted .429 in May with three homers, five triples, seven doubles and 17 RBIs. He hit safely in 25 of 29 games. The 51 hits matched Randy Winn for most hits in a month since the club came to San Francisco in 1958.

Cabrera also set the San Francisco record for most hits in May, passing Hall of Famer Willie Mays' 49 from 1958.

Cabrera came to the Giants in a trade with Kansas City last November that sent left-hander Jonathan Sanchez to the Royals. Cabrera -- who signed a $6 million, one-year deal to avoid salary arbitration -- batted .305 with 44 doubles, 18 homers and 87 RBIs last season.

He is a big reason San Francisco began play Wednesday tied with the Los Angeles Dodgers atop the NL West. Cabrera had been listed in the original lineup for the series finale with the Washington Nationals, batting third and playing left field. Gregor Blanco replaced Cabrera.

San Francisco said it will not make a roster move until Thursday's off day before opening a weekend series at San Diego. The clubhouse was closed before the game when the news of Cabrera's suspension broke.

"Sad, man," Robinson Cano of the Yankees said. "He's a friend. I'm going to be there for him. I never talked to him about anything like that. Sad day."