MIAMI — In tribute to Jose Fernandez, left-handed hitter Dee Gordon stepped to the plate as a righty to lead off the first inning of Monday’s mournful game.

After one pitch, Gordon switched to his customary left side — and homered in the first at-bat for Miami since the death of Fernandez in a boating accident.

Gordon pulled a 2-0 pitch from New York Mets right-hander Bartolo Colon over the wall in right for his first homer of the season. He tapped his chest after crossing the plate and waved toward the sky, and then sobbed as teammates hugged him in the dugout.

It was another heart-tugging moment in a succession of them over the past two days. The Marlins went on to a 7-3 victory.

The atmosphere was funereal at Marlins Park three hours before the first pitch, with players going through their pregame stretching in eerie silence.

Then someone cranked up the sound system, and bouncy reggaeton reverberated throughout the ballpark. It was a nudge toward a return to normal, as the Marlins and baseball began to move on without Fernandez.

The animal race at the end of the fifth inning was canceled, along with other in-game entertainment, and most of the Marlins’ hitters decided to forgo walk-up music. But there was a game against the Mets, the first for the Marlins since their ace died early Sunday.

“This is shallow, but the show goes on,” Marlins president David Samson said. “There has been a lot of talking and a lot of crying and a lot of praying and a lot of trying to make sense of something you can’t make sense of. There is no sense to a life ended like that, in a way that is so meaningless.

“It’s our job to make his life matter, so we’re going to do that forever, and forever starts today.”

Fernandez made his major league debut against the Mets in 2013 and was scheduled to face them again Monday night in his final start of the season. Instead, Miami and the Marlins mourned the loss of the 24-year-old pitcher, whose talent and captivating personality were a combination unmatched in the sport.

Fernandez and two other men were killed when his 32-foot SeaVee slammed into a rock jetty that extends off the southern tip of Miami Beach at about 3:15 a.m. Sunday, a medical examiner said.

Fernandez was originally scheduled to pitch Sunday before his start was moved back a day. The change may be the reason he decided to go on the late-night boat outing.

“If he had pitched yesterday, maybe fate would be different,” Samson said. “I’ve been thinking about that a lot.”

Manager Don Mattingly said, “Obviously it crosses your mind.”

The Marlins’ game Sunday against Atlanta was canceled, and when they took the field Monday for batting practice, Fernandez’s name and number hovered over the field on the huge video screen. Gordon wore a T-shirt that said “RIP,” with a photo of Fernandez shaped as the “I.”

For the game, the players decided to wear Fernandez’s No. 16, with hastily made uniforms flown in. His number was also stenciled on the back of the mound.

The pregame ceremony included a slow, solemn solo trumpet rendition of “Take Me Out to the Ballgame.” Following the national anthem, New York manager Terry Collins led his Mets across the field to share hugs with the Marlins, and fans briefly chanted “Jose, Jose.”

The Marlins then clustered around the mound and put their hands to the dirt. Some scratched out Jose’s number or a message of love, and some just rubbed the mound — his mound. His career record at Marlins Park was 29-2.

Fans established a makeshift memorial on the plaza outside the ballpark entrance, leaving dozens of flower arrangements — daisies, carnations, roses and lilies, the result as colorful as Fernandez’s personality. There were also candles, and messages scrawled on balls, balloons, photos and jerseys.

The situation was emotional even for the Mets, who are in the thick of the chase for an NL wild card with one week left in the season. On their dugout wall hung a Mets jerseys with Fernandez’s name and number.

“Hearts are heavy,” New York outfielder Jay Bruce said. “From a professional standpoint, you just try to prepare and play the game and respect the game. But I can’t even imagine what it’s like over in that other clubhouse.”

Collins spoke about Fernandez in the present tense.

“He epitomizes what the game’s about,” Collins said. “Our game is bigger than a lot of things. It will always go on. We’ll remember Jose. You’ve got to play the game in his honor. He would want to be out there.”

Plans for a public funeral had not been finalized, but it was expected to be Thursday, the Marlins’ final off day of the season.

Fernandez defected from Cuba at age 15, won the NL Rookie of the Year award and became a two-time All-Star. His enormous popularity in South Florida bridged the divide between the franchise and fans antagonized by too much losing and too many payroll purges.

Fernandez left behind a girlfriend who is expecting their first child, the mother who came with him to the United States and the grandmother who helped raise him.

On Sunday evening, the entire team took two buses to Fernandez’s family home and met for 45 minutes with his mother, grandmother and other relatives and friends.

Fernandez’s agent, Scott Boras, spoke to reporters near the batting cage — or at least tried to. He said he paid his respects to the family before coming to the ballpark.

“His mother wanted me to tell everyone how she felt,” Boras said. “She showed me pictures of him as a boy. She actually made his uniform when he was 7 or 8, with Cuban red pants.”

Boras then cut short the interview because he couldn’t stop crying.