Micky Mellons’s side need one more win in their final two games to make sure of a return to League One.
The hosts opened up a 12th-minute lead when central defender Ellis powerfully headed in a Bobby Grant corner from six yards.
It set the tone for a lively first-half display from the Shrews with York goalkeeper Michael Ingham needing to be alert to keep out a stinging free-kick from Grant and also an effort from close range by Tyrone Barnett.
Connor Goldson also flashed a header just wide from a Liam Lawrence corner.
York, having made sure of survival at the wrong end of the table in midweek, were not without their chances and Shaquile Coulthirst’s shot from the edge of the box produced a sharp save from keeper Jayson Leutwiler low to his right.
Leutwiler continued to impress between the posts for the hosts in the second half, tipping a long range deflected shot from Russell Penn over the bar and saving well again from Coulthirst.
Jean-Louis Akpa Akpro squandered a late chance to make it more comfortable for Shrewsbury when he fired straight at Ingham with only the York keeper to beat.