Lorenzo Insigne came off the bench to score the winner after Dries' Mertens brace for the win.
“I expected this, because I knew that to win here, we had to sacrifice ourselves and play with intelligence," Ancelotti told Sky Sport Italia.
“We fought hard, it was a fascinating match and we stayed focused for 90 minutes. It's a great result."
He continued: “We started strong, took the lead, struggled a little and then got it back under control. Those who came off the bench gave an excellent contribution and it's a wonderful night for everyone.
“I said beforehand that there were two very important games against Salzburg. We won the first, but the second is still to come and we believe that we can do better.
“Maybe not everyone knows about RB Salzburg, but they are a very, very dangerous team, especially on their own turf, and we had to try everything to get the better of them here."