Outfielder Yoenis Cespedes will miss the rest of the season because of a right hamstring strain, the New York Mets announced Monday.

Cespedes, who was placed on the 10-day disabled list on Saturday, had an MRI on Monday that confirmed the initial diagnosis. With a recovery timeline of six weeks and the Mets out of postseason contention, the injury effectively ends the slugger's season.

Cespedes, 31, played in just 81 games this season due to injuries and batted .292 with 17 home runs and 42 RBIs.

The Mets also got bad news on third baseman David Wright, who had been on a rehab assignment while attempting to come back from last year's neck surgery for a cervical disk herniation.

"After playing in a few games, I continued to have shoulder pain," Wright said in a statement released by the team. "So I decided to go to the doctor and get it checked out. Will make any decisions going forward after my appointment."

The 34-year-old Mets captain, who last played in a major league game in May 2016, will be reexamined in New York later this week.

"I just hope he's able to keep playing,'' Mets manager Terry Collins said. "That's the key for me."

The Mets did offer positive updates on ailing starting pitchers Matt Harvey (shoulder) and Noah Syndergaard (lat muscle), as Harvey is expected to return for Friday's start against Houston, while Syndergaard is slated to throw a bullpen session on Wednesday.