City have taken up the option of recalling Ribeiro because of defensive injuries and suspensions ahead of the FA Cup tie against Cardiiff City at the weekend.
"We had the 24-hour recall clause in Ribs' loan at Stockport and we've utilised that to bring him back to the club," manager Gary Johnson has said.
Ribeiro made seven appearances for The Hatters having moved on loan to Edgeley Park in November.