Hibernian face a battle to stay in the Scottish Premiership after a 1-0 defeat at home to Kilmarnock in their final game condemned them to 11th position and a relegation play-off.
Terry Butcher's side needed to win at Easter Road on the final day to leapfrog Killie and secure their top-flight status after a terrible run of results.
However, former Rangers striker Kris Boyd fired past Ben Williams in the 44th minute for his 22nd goal of the season to seal safety for Kilmarnock.
Hibs have won just once in their past 18 matches and are in real danger of joining Edinburgh rivals Hearts in relegation to the Championship.
The Easter Road side will now face a two-legged play-off final against either Hamilton Academical, Falkirk or Queen of the South on May 21 and 25.
City rivals Hearts, who would have finished three points above Hibs if it hadn't been for their 15-point deduction for entering administration, finished the season with a 1-1 draw away to St Mirren.
In Saturday's other match, Ross County claimed seventh spot with a 3-2 win away to Partick Thistle, who finished 10th.
The final games will be played on Sunday, with champions Celtic entertaining Scottish Cup finalists Dundee United and Aberdeen hosting Motherwell in a decisive game for second place.