Zika virus concerns have forced the Pirates-Marlins series out of Puerto Rico, with the two games instead shifted to Miami this month.
Major League Baseball and the players' union made the announcement Friday. Pittsburgh and Miami will meet May 30-31 at Marlins Park.
The union had asked Commissioner Rob Manfred to relocate the games after several players expressed fears about getting and possibly transmitting the Zika virus.
The U.S. Centers for Disease Control and Prevention has said Zika can cause a birth defect called microcephaly, where infants are born with unusually small heads. The virus is most often spread by mosquito bites, but it also can be spread through sexual intercourse.
"You trust the process that the union and the league is going to do what's best for everyone and make sure they take care of everyone," Marlins manager Don Mattingly said before Friday night's game against Philadelphia.
The CDC had spoken to players and staff from the Pirates and Marlins about the potential risks.
"Go visit my beautiful Puerto Rico !! Still dont understand why MLB cancel the games down in PR! Wow!" tweeted Cardinals catcher Yadier Molina, who's from the island.
Manfred said "players who objected to the trip because of their specific family situations should not be forced to travel to Puerto Rico," MLB and the union said in a release.
"Because too many regulars on both clubs fell into that category, Commissioner Manfred had no choice but to relocate the games," it said.
Pittsburgh and the Marlins were originally scheduled to play the series in Miami when the original draft of the schedule was made last year. On Nov. 19, MLB said the games would be played in Puerto Rico, the homeland of Pirates Hall of Famer Roberto Clemente and many other big leaguers.
MLB has played several regular-season games at Hiram Bithorn Stadium in San Juan in the past. MLB said it hoped to play again in Puerto Rico sometime in the future.
Puerto Rico has had 785 confirmed Zika cases, including its first death from the virus.
"It's ironic that athletes are willing to go to Brazil to the Olympics and don't want to come to Puerto Rico," Puerto Rico governor Alejandro Garcia Padilla recently told local newspaper El Nuevo Dia.
Brazil is at the center of the Zika outbreak, putting Olympic host Rio de Janeiro in the spotlight with 10,500 athletes and up to 500,000 foreign tourists expected for South America's first games.
Nothing has been canceled at the Games, and nearly all athletes still plan to compete.
On Wednesday, Garcia Padilla said Miami and Tampa also have Zika cases, and suggested players who asked for the games to be moved "are not very smart."
The decision to shift the games from Puerto Rico is another blow to an island mired in recession and unable to pay $72 billion in public debt. The U.S. territory has been suffering through more than a decade of economic decline since Congress phased out tax cuts that made the island a center for pharmaceutical and medical equipment manufacturing.
Puerto Rico missed nearly $370 million on a bond payment Monday and officials warned of worse to come without relief from Congress. Garcia Padilla said he had no choice but to suspend the debt payment to avoid cutting essential public services such as schools and medical care.
MLB and the union will make contributions to help combat Zika in Puerto Rico. Also, Manfred and several former players plan to hold youth clinics and events on the island later this month.