Defending champions Real secured a 3-2 win over Celta Vigo on Sunday to keep their title dream alive going into the last four matches in the campaign.
Barcelona are unbeaten in their last 15 league games, and beat Real 3-2 after extra time to win the Copa del Rey last weekend.
"We're going to prepare well, we're going to put up a good fight," Ancelotti said in a post-match press conference.
"It's not going to be decisive but it's almost there."
The coach blamed injury-related absences for Real failing to hold onto a 3-0 lead, with Celta Vigo scoring twice within seven minutes to put the hosts under pressure.
"You have to bear in mind that there were six defenders missing and we are not always able to fix these things. Yes, we could have handled it better, we suffered a bit but it's a nice win," Ancelotti said.
Forward Rodrygo, who missed the Celta Vigo game with a fever, is likely to be fit for the Barcelona trip with a week to recover, Ancelotti added.