Hamburg's victory over Slavia Prague ensured Villa will progrees from Group F despite an embarrassing 2-1 home defeat to Slovakian minnows MSK Zilina, but Portsmouth are out after going down 3-2 at Wolfsburg.
At Villa Park goals from Vladimir Leitner, who was sent off in the second half for two bookable offences, and Peter Styvar put MSK in control before Nathan Delfouneso pulled one back on his full debut for Martin O'Neill's side.
Villa could not find an equaliser but still join Hamburg and Ajax in reaching the last 32.
A David James error handed Zvjezdan Misimovic Wolfsburg's winner - although the England man partially atoned with a penalty save from the same player five minutes later.
Earlier, Edin Dzeko fired the hosts into the lead before Pompey hit back through Jermain Defoe and Arnold Mvuemba. Christian Gentner levelled things before the break.