The 76ers welcomed back their best player and got a much-needed victory.

Donning a gray mask, Joel Embiid finished with 18 points and a game-high 11 rebounds, one block and one steal as the Sixers defeated the Miami Heat, 99-79, Friday night in Game 3 of their Eastern Conference semifinals series at the Wells Fargo Center. The Heat will take a 2-1 series edge into Game 4 there Sunday night at the same arena.

This win guarantees that this best-of-seven series will go at least five games. And it could be the win the Sixers needed to make this a competitive series.

“Down 2-0, I had to do really everything possible to be out there, really no matter how much I was feeling,” Embiid said. “I’m just glad that we got the win.”

» READ MORE: Sixers’ Joel Embiid to play in Game 3 vs. Miami Heat in Eastern Conference semifinals

The Sixers lost Games 1 and 2 by double-digits at the FTX Arena in Miami earlier this week as Embiid was sidelined with a concussion and orbital fracture near his right eye.

He was cleared to play Friday after participating in a 15-minute pregame warmup. Embiid’s return came after the MVP finalist cleared the concussion protocols Thursday and participated in Friday morning’s shootaround. At the time, he had been upgraded from “out” to “doubtful.”

Danny Green finished with 21 points on seven three-pointers. Tyrese Maxey also had 21 points and six assists, while James Harden added 17 points, eight rebounds, and six assists.

The Sixers also did a better job of shooting three-pointers and rebounding than they had in the first two games. They shot 48.4% from behind the arc and had a 44-35 rebounding advantage. This shooting performance came after they made just 14-of-64 three-point attempts and had been outrebounded, 91-71, in the first two games.

“It was very annoying,” Embiid said of watching the first two games. “Obviously, we didn’t make shots. But we also made a lot of mistakes, whether it was offensive rebounding or turnovers. The big fella, Bam [Miami center Adebayo], was dominating, andI was really [ticked] off watching that other big man go and play well against my team.

“But it’s unfortunate. Can’t take it back. Now we have to just focus on the next game.”

Adebayo averaged 23.5 points in the first two games on a combined 15-of-21 shooting to go with 10.5 rebounds. On Friday, he was held to nine points on 2-for-9 shooting and three rebounds. Abebayo was a game-worst minus-22.

“He’s a huge factor even when he’s not scoring,” Green said of Embiid. “Defensively, rebounding, they killed us on the glass [in the first two games]. Bam did, P.J. [Tucker] did. Even tonight, they got some offensive boards. But it’s a big difference when he’s guarding Bam.”

Former Sixer Jimmy Butler finished with a game-high 33 points to go with nine rebounds.

But the focus was on Embiid in his first game since he was injured by an elbow from Toronto Raptors forward Pascal Siakam near the end of the Sixers’ Game 6 victory to clinch the first-round series.

“When it happened, obviously we won,” Embiid said. “After we figured out what would really happen, I didn’t think about it. I just thought about what I was going to do to make sure I was back at any point in this series. Whether it was Game 1 or Game 2 or Game 3 or Game 4, I was just doing whatever possible, whatever was possible to try to come back.”

This marked the second time Embiid wore a mask in the playoffs due to an orbital fracture. He wore one in 2018 against the Heat (first round) and the Boston Celtics (second round) .

Like that postseason, Embiid’s eyewear is stronger than a normal mask. It is made of carbon and polycarbonate. The only difference is the last mask had a goggle-like covering over the eyes.

While in concussion protocols, the five-time All-Star didn’t do much. In fact, he didn’t start running until the last couple of days.

Statistically, Embiid didn’t do much on offense in the first half.

He missed five of his seven attempts en route to seven points. However, his presence alone made a difference as he grabbed seven rebounds.

“He’s a big impact,” Heat coach Erik Spoelstra said. “This is what you have to expect – he is an MVP caliber player and he is usually in the running for Defensive Player of the Year, you know you have to be very intentional on both ends.

“We are not expecting it to be easy, they were a very good team all year, so were we. We are expecting him to be available all series and we’ll just have to figure it out.”

Embiid’s presence combined with the solid play from Harden (15 points) and Danny Green (nine) enabled the Sixers to take a 41-34 halftime cushion.

Danny’s Day

Green struggled mightily from the field in the first two games. In Game 1, he shot 2-for-6, including 1-of-5 on threes. Then in Game 2, the small forward was 1-for-10 while making 1-of-9 threes.

He broke out of that slump on Friday.

“It felt good to help my team and do my job,” Green said. “I’m not in any way, shape or form satisfied. We know we aren’t taking any deep breaths or exhaling. We know we have to win another game.

“So we have to stay locked in.”

Green’s 21 points and seven three-pointers came on nine attempts — all three-pointers. His hot hand also enabled the Sixers to break out of their three-point shooting slump. They made 16 of 33 three-pointers. Maxey joined in on the fun with 5-of-6 shooting on three-pointers.

Butler takes over third quarter

The Sixers had a tough time defending Butler in the third quarter.

He scored 14 of the Heat’s first 25 points of the quarter as they closed the gap to 62-59 before he was subbed out with 1 minute, 33 seconds left in the quarter. Butler made 5-of-8 shots and all four of his foul shots. He also had three rebounds and two assists while on the court for 10:27 in the quarter.

Heat sixth man Tyler Herro buried consecutive three-pointers to keep it a three-point game (68-65) heading into the fourth quarter.

P.J. Tucker tries to rough up Sixers

Miami’s Tucker tried to play the role of the bully.

He and Tobias Harris had to be separated late in the third quarter after a dead ball. Both players were subbed out after the altercation. Before leaving the floor, Tucker and Matisse Thybulle almost got into it. Then Tucker elbowed Thybulle in the back on a play early in the fourth quarter. Thybulle retaliated with a shove. Both players received technical fouls on the play.

That altercation led the Sixers sell-out crowd to start chanting, “P.J. [stinks]!”

“P.J. does what he does,” Green said of Tucker’s actions.

Asked how the Sixers will combat that?

“We don’t have soft guys in this team,” Green said. “We don’t back down. At the same time, we have to be smart. Not going to get into a tussling match and get double-technicals. You know, just play smart and don’t take any cheap stuff happening . Don’t give any cheap stuff, either. Just play basketball. But at the same time, be physical — just as physical as they are.

“We are not going to back down. We are going to check people, get into bodies. We are going to do what we can. We’re here, too. We’re here to win.”

The Sixers are far from intimidated.

“Both sides have grown men on our side,” Maxey said. “We can’t let that intimidate us. I mean, that’s how they want to play. They play tough. They are a veteran team ... and they are gritty, and you’ve got to hold your own and come together as a team.

“At the end of the day, it’s a fight. Like I said, we are going to take the fight to them instead of being on our heels and being a counterpunching team.”

Inconsistency continues for Harden

In the first two games, Harden’s scoring tailed off after intermission. That was, once again, the case on Friday. The Sixers point guard’s 15 first-half points came on 3-for-6 shooting. However, he scored two points on 1-for-4 shooting in the second half.

‘We put him in the right spots,” Rivers said. “But he does several things [in the second half]. The last four minutes, he got the ball to Tyrese to run the double drags instead of him. You know that was subtle, but that was huge for us and that’s the stuff he’s doing for us. It’s been really good.”

Harden will tell you his inconsistency is kind of by design.

He’s attacking more in the first half as way to help set the tempo. Then he becomes more of the facilitator in the second half.

“We found something that worked late in the third and I think that fourth quarter,” he said, “and we just stuck with it. Whether I’m scoring or I’m in action or off the ball, I’m ready to go.

“You see in that fourth quarter, being a playmaker, getting guys easy shots.”