Crewe Alexandra will play their football in League One next season, despite being beaten by Bradford City on the final day of the season.
Billy Clarke's first-half goal was enough to see the Bantams past the Railwaymen, who relied on scores elsewhere to keep them in the division.
Crewe, who had been unbeaten in seven games heading into today, started in scrappy fashion as both Clarke and Jon Stead fired over for the visitors.
Clarke then gave the Bantams the lead when a free kick arrived at his feet. The Irish forward produced a neat turn and shot that left Paul Rachubka beaten.
Alex seemed to be finding their feet late in the half as Lauri Dalla Valle threatened with an effort that went just off target before James Jones brought a save out of Ben Williams.
At one stage in the second half, Crewe languished in the bottom four as other side in the relegation zone looked to be climbing out.
Steve Davis threw on Nicky Ajose and Jamie Ness in a bid to rescue their League One status, but chances from Harry Davis and Anthony Grant were as close as the Railwaymen came to an equaliser.
In the end, Crewe were saved by Gillingham's late rally, which saw Notts County drop out of the division.