Sunderland will be joining Pompey in the League One play-offs after they lost 2-1 away at Fleetwood Town.
That means the Black Cats cannot go up automatically either and along with Pompey’s defeat to Peterborough has seen both Luton and Barnsley promoted to the Championship.
Lee Cattermole gave the visitors the lead but Paddy Madden and Ashley Eastham secured the points for the home side.
Sunderland created early chances when Max Power was kept out by goalkeeper Alex Cairns after good work from Chris Maguire before Will Grigg struck the crossbar.
Jack Ross’ side led on the half hour at Highbury, as an unmarked Cattermole guided Lewis Morgan's corner from the right across goal past Cairns and into the bottom left corner.
After the break, Maguire arrowed his right-footed strike just wide of the left post after Grigg's knockdown, while visiting keeper John McLaughlin was forced to keep out forward Madden’s low effort.
Joey Barton’s side were level with 73 minutes played after captain Madden slid the ball right-footed under McLaughlin following Lewie Coyle's pull-back from the right.
Fleetwood’s winner came deep into injury time as centre-back Eastham powered the ball into the top left corner from Ross Wallace’s corner on the right.
The result sees Sunderland remain in fourth position in the table, while Fleetwood are in 11th.
Pompey have 87 points, Sunderland have 85 – the same as Charlton in fifth.
Kenny Jackett’s men finish the season at home to Accrington, while Sunderland go to Southend and Charlton host Rochdale.
Luton and Barnsley each have 91 points and will fight it out for the title on the final day of the season.
The leaders host Oxford, while Barnsley go to Bristol Rovers.