Stevie Wonder closed out the marathon “Tidal X: Brooklyn” benefit at Barclays Center early Wednesday morning with a call for compassion for those affected by recent natural disasters and a challenge to political leaders.

Following a powerful version of “Love’s in Need of Love Today,” Wonder led the crowd in a chant of “If all lives matter, lead us right. Do what’s right so this nation can unite.”

His remarks capped nearly six hours of music and pleas for support from an eclectic slate of acts -- including superstar headliners Jay-Z and Jennifer Lopez, as well as pop group Fifth Harmony and Mexican mariachi singer-songwriter Christian Nodal -- for those suffering due to a string of hurricanes that damaged Puerto Rico and other Caribbean islands, as well as parts of Texas and Florida, and earthquakes in Mexico.

One star who was notably absent from the stage was Beyoncé, who fans had hoped would make a cameo appearance despite not being on the lineup. The new mom of twins Sir and Rumi took a seat in the crowd instead just in time to catch her husband Jay-Z's performance. 

"Y'all think Bey is coming out or something but we ain't doing that tonight," Jay-Z said to the crowd of cheering fans. 

Queen Bey did, however, show face on the event's red carpet, wearing a skin-tight green gown with a thigh-high slit. 

Back onstage, Lopez and “Hamilton” creator Lin-Manuel Miranda were attending their second benefit for Puerto Rico in the past week, following Saturday’s star-studded “Somos Live!” benefit on NBC.

“We’re not done -- that’s why I’m here tonight,” Lopez said, during her set. “It’s a long road ahead and we’ve got to come together … It’s up to us to create the world that we want to live in.”

The concert, which had already raised $3.4 million before it began, was streamed worldwide through the Tidal website, where it solicited further donations and is now available on-demand.

Some of the funds have already paid for cargo planes to distribute goods donated to Gov. Andrew M. Cuomo’s Empire State Relief and Recovery Effort for Puerto Rico.

“When we all pull together, we have the power to affect real change,” Power 105.1 DJ Angie Martinez told the crowd to start the show. “We can and should help each other in times of need.”

Martinez also offered a message to those affected by the natural disasters: “We see you. We hear you. And you matter to us -- today, tomorrow and always.”

Singer-songwriter Luis Fonsi, whose hit “Despacito” racked up 16 weeks at No. 1 this summer to tie the record for the longest-running chart-topper, dedicated the song to his native Puerto Rico, still reeling from Hurricane Maria. “We’re here for a lot of people tonight,” Fonsi said. “We’re here to celebrate music.”

For the most part, the dozens of artists in the tightly produced concert stuck to the music, as everyone from rappers Jadakiss and Fabolous to Spanish dance artist David Bisbal, delivered a song or two and quickly left the stage. Even Jay-Z focused solo on his music, though his set did include the charged “Family Feud” and “The Story of O.J.” from his recent “4:44” album.

However, Pastor Donnie McClurkin of Perfecting Faith Church in Freeport, who called himself “the gospel of the night,” offered a pointed prayer. “We need love,” he said. “We need help in the White House tonight, Lord.”

With Meghan Giannotta