With three wins on the spin, Hammarby fancied their chances at the home of the outgoing champions, and took the lead 17 minutes in when Adrian Lahdo drove through the middle of the Malmo half before the ball fell to Nahir Besara, who tucked the ball away.
It was 2-0 just under 10 minutes later when Hampus Skoglund floated a ball into the box for Paulos Abraham to attack, which he did but cushioning the ball neatly into the bottom corner.
Things went from bad to worse for MFF in first-half added time when the trickery of Montader Madjed was too much for Jens Stryger Larsen, who turned the ball into his own net for 3-0.
Just before the hour mark, Malmo pulled one back when Martin Olsson pounced on a loose ball inside the area, but that was as good as it got for the hosts, who have won only two of their last eight in the Allsvenskan and are six points off the European places with two games to play.
The 3-1 win seals the runners-up place for Hammarby for the second time in as many years, meaning they will enter the UEFA Conference League qualifiers next summer.
A side one win away from joining them are third-placed GAIS, who put four points between them and the chasing pack with a 2-0 win at Brommapojkarna.
As in Malmo, the damage was done in the first half - 33 minutes in, Rasmus Niklasson cut inside and took aim, and BP goalkeeper John-Oliver Lacayo made a complete hash of what should have been a routine save, and instead let the ball trickle into the bottom corner.
The, five minutes before the break, Kevin Holmen played the ball across goal for Ibrahim Diabate to tap home and seal the victory.
With no wins in four, the Bromma Boys are four points above the bottom three and thus not quite safe yet. As for GAIS, a third successive win has put them in touching distance of a major UEFA competition for the first time since 1990.
