Joe Cole and Kevin Nolan were on target on Saturday as the Hammers inflicted a 2-0 defeat on the Welsh club, who were making their first appearance in the top flight since 1962.
Cardiff have spent close to £30million in the transfer market this summer but failed to trouble goalkeeper Jussi Jaaskelainen at any point as West Ham coasted to victory.
Allardyce believes the newcomers should look to Southampton, who made a poor start to their return to the Premier League last season, for comfort if results go against them.
"With the squad Cardiff have they'll hopefully get the results they're looking for. The challenge for them will be not getting too worried if they don't start well," he said.
"The example of that is Southampton last season. Nigel Adkins eventually pulled them out of the bottom three superbly well. And his reward for that was the sack!
"If it's to be your first game in the Premier League, you'd want it at home, not away.
"When we came up from the Championship we'd won more games away from home, but last season in the Premier League it was a huge task to pick up points away.
"Your home form is what you need to get right to stay in the Premier League."
Cole finished the opener beautifully, collecting a pass from Matt Jarvis, turning and skillfully directing the ball into the bottom right corner of the net.
The 31-year-old was otherwise wasteful, although Allardyce stresses that it was his movement that put him in positions to score.
"Joe Cole's an England player, timing his runs and knowing where to run is what he's all about," he said.
"To have the opportunity to get a hat-trick in the first 45 minutes, well his hardest chance was the one he scored from."
Cardiff manager Malky Mackay took heart from the Bluebirds' performance, even though they had to wait until late in the match for their first real chance which was skied over the crossbar by substitute Nicky Maynard.
Mackay accepts Allardyce's point that their form at Cardiff City Stadium will determine their Premier League future.
"We were a match for West Ham in terms of the overall ebb and flow of the game," he said.
"Sam knows what he's talking about and it was always going to be a tough game at Upton Park. I've played here so I knew what it would be like.
"We need to make our stadium a fortress and have to pick up as many points as we can on the road. We just have to be slightly better than we were."