Zlatan Ibrahimovic scored a fantastic opening goal and set up the second as Sweden held on for victory in their first Euro 2012 warm-up match against Iceland.
The AC Milan striker broke the deadlock in the second minute before teeing up Ola Toivonen 12 minutes later at the Gamla Ullevi in Gothenburg.
Kolbeinn Sigthorsson narrowed the deficit in the 27th minute and although Christian Wilhelmsson restored the two-goal advantage, Hallgrimur Jonasson's stoppage-time strike ensured a nervy finale.
Victory over former national team manager Lars Lagerback's men was Sweden's first of two warm-up matches before they begin their European Championship campaign against co-hosts Ukraine on June 11 in Kiev's Olympic Stadium.
They made a strong start this evening, Ibrahimovic firing them into an early lead with a stunning low volley from Sebastian Larsson's right-wing cross.
Ibrahimovic's cross from the left side of the penalty area then allowed fellow striker Toivonen a close range finish.
Sweden, who also play England and France in Group D, looked to be on their way to a convincing win but they were pegged back when Sigthorsson headed home Ari Freyr Skulason's cross from the left.
Wilhelmsson then volleyed past Iceland goalkeeper Hannes Thor Halldorsson with 13 minutes remaining as Sweden looked to have wrapped up victory.
But Iceland, who took a two-goal lead against France at the weekend before going down 3-2, refused to lie down.
Jonasson converted Johann Berg Gudmundsson's corner but the strike was too little, too late.