Former Oxford striker Matt Green opened the scoring for the Stags, heading in after Sam Slocombe's weak attempt to punch a cross clear.
Jonjoe Kenny crossed for Danny Hylton to equalise with a low header past keeper Scott Shearer before half-time.
Hylton fired in his second from Zeli Ismail's cross, but Thomas levelled after Ryan Tafazolli had hit the bar.
The hosts could have won the game for in injury time, but Hylton mishit his effort from five yards out and sent the ball wide.
The result means Mansfield climb to fourth in the table, four points behind third-placed Oxford.
Jack Thomas' late header rescued a point for Mansfield Town against League Two promotion rivals Oxford United.