Spence, 23, whose initial month-long stay with the Sky Bet League One club ended after their 3-2 home defeat to Bradford on Saturday, has played every minute of every game since joining Karl Robinson's side.
The former England Under-21 international will now be available for the Dons' league fixtures against Colchester, on Tuesday night, Coventry, Wolves, Port Vale, Crawley, Brentford and finally Colchester and Crewe in the new year.
Spence will also be eligible for Dons' FA Cup second-round tie against Dover Athletic next month.
Robinson said: "First of all we're thankful to West Ham United and their manager Sam Allardyce for allowing us to keep him until the new year.
"He's done wonderfully well since signing for us and we're very fortunate to have him until January. He is a typical MK Dons centre-back and they are hard to find.
"This now gives us consistency in the back four and it's important over the forthcoming weeks and months while Antony Kay is out, that he'll be there to fill that void."