They still have to negotiate home games against Villarreal and Real Sociedad, along with an away match against Levante, but it will require something special to end their 42-match unbeaten league record stretching 13 months.
Ernesto Valverde's side now need to avoid a loss in their final three fixtures - two of which are at home - and the most hard of those was the visit of Real.
Minutes before Messi put Barcelona ahead, Ramos had an animated conversation with Hernandez, as the Spanish worldwide went nose to nose with the man who's been named La Liga's top official for the past three years.
"I believe [the Jordi Alba challenge] was a penalty, Sergi Roberto caught me in the face [for a red card], but it's gone now". After the match, Zidane reported that Ronaldo had said it was only a "small problem" but in the same breath admitted the striker was a "little bit worried" by the swelling.
The Catalans produced some of their best football of the game at the start of the second half and took the lead as Lionel Messi finished after great work from Luis Suarez seven minutes after the break.
"Our quest continues to finish the league without a loss", said Andres Iniesta, who played his 38th and final game against Madrid before he leaves the club after 16 seasons this summer. "Dead rubber" is what many called it and in the grand scheme of things, that is exactly what it was at the Camp Nou Stadium but if you go by how the action transpired on the pitch, it was anything but a game without consequences. "I do not know if in the second half he would have done it in other ways".More news: Deadpool Is in Celine Dion's New Music Video
More news: Giuliani: Trump doesn't have to comply with potential Mueller subpoena
More news: Trump says date, place set for North Korea summit
Real struggled to capitalise on their one-man advantage until the 72nd minute, when Bale raced onto Asensio's pass and whipped the ball first-time into the top corner.
The home fans were raging as the half-time whistle blew but, with Marco Asensio on for Ronaldo, they were celebrating eight minutes after the restart.
Ronaldo's goal against Barca was a scrappy one as he bravely threw himself at the ball to get it over the line ahead of Gerard Pique.
Casemiro has suggested he would rather be in the Champions League final than win La Liga after Barcelona captured the title.
La Liga will introduce video technology next season and Zidane, rather pointedly, said: "Then we'll see how a match like this turns out". Guess we will find out next season. "I never do", Madrid coach Zinedine Zidane said.