Southend confirmed their League One title with a 1-0 win at home to Bristol City - and they will be joined in the Coca-Cola Championship next season by Colchester, whose goalless draw at Yeovil was just enough.
At the other end of the table Milton Keynes Dons, with a goalless draw at Rotherham, and Hartlepool - after a 1-1 draw at home to Port Vale - were relegated.
Vale's Michael Cummins had put the visitors ahead - and although James Brown's 86th-minute goal set up a frantic finish, the Pools went down.
That meant survival joy for Rotherham and Blackpool, who drew 3-3 at home to Gillingham.
Wayne Gray scored Southend's goal in the 87th minute - and despite no goals, Colchester celebrated securing their place in the second tier of English football for the first time. That denied Brentford, who will now play Swansea in the play-offs.
Joining them in the end-of-season knockout are Huddersfield and Barnsley.
The third-placed Bees drew 2-2 at Bournemouth only to hear Colchester had managed the point they needed.
Sam Sodje (22), who was later sent off, and Andrew Frampton (65) scored either side of Steven Foley's 45th-minute effort for the hosts who had Adam Griffiths dismissed before Steve Fletcher scored a late equaliser.
A hat-trick for Leon Knight and another for Rory Fallon saw Swansea beat Chesterfield 4-0.
Huddersfield's match at Swindon finished goalless, while Barnsley's 2-1 win at Walsall kept them in the play-offs.
Marc Richards (31) opened the scoring for Barnsley only for Dean Keates (59) to equalise from the penalty spot.
Ian Roper was sent off for Walsall, before Daniel Nardiello (83) grabbed the winner from the penalty spot.
Bradford's Dean Windass scored the only goal which ended Nottingham Forest's play-off hopes.
Two goals from Keigan Parker (56 & 69) - after Matthew Blinkhorn's opener - put Blackpool 3-2 up against Gillingham but Michael Flynn scored a late equaliser after Darren Byfield had scored twice for the visitors.
Billy Sharp's 88th-minute goal earned Scunthorpe a point at Oldham after David Eyres had put the home side ahead on the stroke of half-time.
Lewis Guy (12) and Stephen Roberts (43) scored in Doncaster's 2-0 victory at Tranmere.