The 23-year-old has made 19 appearances in all competitions for Michael Appleton's side this season, scoring one goal.
Ruffels, a former Coventry City trainee, was previously out of contract this summer.
The U's travel to Luton Town on Wednesday in the last four of the EFL Trophy.
Oxford United midfielder Josh Ruffels has signed a new contract with the club until the summer of 2018.