The top eight skaters competed for medals in a super final, where reigning champion Wallberg was awarded 82.40 points, a clear improvement compared with his first run.
With one skater left, the Swede was in third place. Then Australia's Cooper Woods stepped forward with a huge skate and knocked Wallberg down to fourth place.
"I would have rather come eighth than fourth," said a disappointed Wallberg.
The 25-year-old has been suffering from back pain and has been taking painkillers.
"It's been a hell of a year. I've been proud of myself all day and tried to enjoy every ride. Mentally there's not much to complain about; I did what I could."
Cooper Woods finished on the same score as Canada's Mikael Kingsbury, 83.71, but took the gold thanks to a better first run.
Ikuma Horishima of Japan took the bronze.
Wallberg now faces parallel moguls on Sunday alongside Olympic debutant Rasmus Stegfeldt, who finished in 18th place in the final.
"I can ride fast, so I'm just going to recover a bit and digest this and we'll ride on Sunday," Wallberg tells SVT.





