Ousmane Dembele's second-half strike gave Barcelona a 1-0 win over 10-man Real Sociedad in their Copa del Rey quarter-final on Wednesday, stretching their unbeaten streak to 12 games.
Real Sociedad came into the match on the back of nine consecutive wins in all competitions and almost scored in the 29th minute when Japanese youngster Take Kubo's strike hit the bar.
But their hopes of inflicting a surprise defeat on Barca at the Camp Nou were hit when forward Brais Mendez was shown a straight red card in the 40th minute for a wild challenge on Sergio Busquets.
Barcelona were the better side for most of the match after that but only scored once thanks to a brilliant counter-attack by man-of-the-match Dembele in the 52nd minute.
The electric winger ran through the right channel after receiving a perfectly placed long pass from his France team mate Jules Kounde and lashed an unstoppable right-foot strike into the top corner.
Sociedad should have equalised seven minutes later but Alexander Sorloth missed a sitter, skying a shot from inside the six-yard box from a Kubo cross.
After Gavi volleyed against the crossbar from a great cross by Dembele in the 68th minute, Real made a late push and could have scored on at least three occasions, with Barca keeper Marc-Andre ter Stegen making a string of saves to secure the win.
"It was a struggle for us after they were one-man down because they closed down well and defended relentlessly," Barca defender Ronald Araujo told Movistar Plus.
"I'm sure (coach) Xavi will give us a slap on the wrist, we probably should have closed out the game earlier. Now we need to correct the mistakes and move forward. I'm happy because we won at home and we continue on a good run."
Osasuna joined Barcelona in the semi-finals after they beat Sevilla 2-1 later on Wednesday thanks to an extra-time goal by Abde Ezzalzouli.
Chimy Avila opened the scoring for the hosts in the 71st minute but Youssef En Nesyri equalised in the 94th minute, taking the match to extra time.
Substitute Ezzalzouli scored the winner nine minutes into extra time on a counter-attack, slotting a right-foot shot inside the right post.
In the other quarter-finals, Real Madrid face Atletico Madrid and Valencia meet Athletic Bilbao on Thursday.