The pair had only been on the pitch a handful of minutes when they teamed up to score the game's only goal in the 88th minute, MacLean floating a ball from the left and to the unmarked Williams who headed home at the far post.
Most of what had gone before was dull and contained few chances. The best of those came in the first half for a County side who had lost only three of their previous 14 matches.
Alan Judge got into the penalty area in the 11th minute but slipped at the vital moment, before the midfielder unleashed a terrific drive which came back off the underside of the crossbar midway through the half.
Yeovil struggled in vain for most of the second half and had four players booked as frustrations grew. But they did come close to scoring before their eventual winner when Jon Obika and Kieran Agard failed to get a touch when Gavin Massey sent the ball into the six-yard area.