The on-loan Liverpool forward started his first game since November after injury and scored the winner to earn his temporary club just a third Premier League win in two months.
And Allardyce thought Carroll, who could join West Ham on a permanent basis in the summer, was the best player against Swansea despite not being fully fit.
"I think Andy has made the difference today, no disrespect to [Marouane] Chamakh and Carlton Cole," Allardyce told Sky Sports.
"He is a big strong lad with a lot of ability. As we saw today, it was not just about his heading ability, even though that was the winning goal.
"It was about his hold-up play, his movement and the trouble he caused Swansea. I think everybody else could build off Andy and we created numerous chances."
West Ham were denied by excellent Swansea goalkeeper Gerhard Tremmel on several occasions but Allardyce was at least pleased to see his struggling team making opportunities.
"It has been a great day from that point of view and, as long as we keep creating the chances - particularly at home, we will sooner or later start putting more in the back of the net," he said.