The Spain international suffered the knee injury in a challenge with Villarreal's Yeremy Pino, and he was in tears when he left the field on a stretcher, with the worst being feared.
Carvajal took to social media in the early hours of Sunday morning to reveal that he had damaged his cruciate ligament, which will lead to him undergoing an operation and spending a long period on the sidelines.
"A serious injury to the cruciate ligament has been confirmed, I will have to undergo surgery and be off the pitch for a few months," he wrote on Instagram.
"I am already looking forward to starting the recovery and coming back like a beast. Thank you all very much for your messages, I feel very loved."
Carvajal suffered serious knee injury against Villarreal
Carvajal is now expected to be missing for the rest of the season, handing Real Madrid head coach Carlo Ancelotti a major problem at right-back, and the club could potentially enter the winter market for a replacement.
However, until the transfer window opens, Lucas Vazquez is set for a run in the side at right-back.
"Will we sign a right-back? Lucas gives us a lot of confidence," Ancelotti told reporters when questioned during his post-match press conference on Saturday night.
According to Defensa Central, Real Madrid also consider Eder Militao as an option at right-back, but with David Alaba still missing due to a knee injury, that scenario would see Aurelien Tchouameni moved into the middle of the defence alongside Antonio Rudiger.
Ancelotti opens up on Carvajal injury blow
"It looks like quite a serious knee injury, but we'll have to evaluate it in the next few hours. The dressing room is sad and worried because something has happened that happens many times in the season and unfortunately it has happened to a very important player for us," Ancelotti added after the 2-0 win.
"He's an essential player for us because of his experience, professionalism and seriousness. We're going to wait, I've spoken to him and he's sad and disappointed. We can't do much about it now.
"We have to wait for the medical assessment and then think about getting him back. I spoke to the doctor and he told me it was a knee injury. He didn't tell me what it is. They have to do some tests. It's an injury that I hope will be as minimal as possible.
"When something like this happens to a player like Dani, who is always motivated, it affects all the players and the whole team. We have to respond. Last year we reacted very well to the injuries we had and this year we have to make a further effort to ensure that the injuries serve as a source of motivation for the rest of the squad, as was the case last year."
Real Madrid will return to La Liga action on October 19 away to Celta Vigo, before resuming their Champions League campaign at home to Borussia Dortmund three days later.