The left back, who had been on loan with Barry Fry's side for the last three months, has signed a contract with his former club until the end of the season.
"I am absolutely delighted with the signing of Tom Williams until the end of the season," Fry told the Posh official website.
"I have called in a few favours and Birmingham City have been absolutely fantastic with everything. Tom has had his contract cancelled by mutual consent and has agreed to come here until the end of the season to try and help us avoid relegation.
"We will try and reach an agreement about a longer deal at the end of the season, but Tom has other irons in the fire. Posh will be one of those options, but to get a player of Tom's calibre here until the end of this season is a real coup for the club."
Williams, who has played in just four games for Blues since joining the club from Peterborough in March 2002, spoke of his frustrations at having failed to make the breakthrough at St. Andrews following his signing two years ago.
"I do look back on my time at Birmingham City with a bit of frustration but when a big club comes in for you like what happened with the Blues you have to have that experience," Williams told his new clubs official website.
"At the end of the campaign I will become a free agent, so I will be working hard at Posh to keep fit and play games. I am still only 23-years-old, so I have time on my side, and there is still plenty of time for me to move back up the leagues."
Defenders Contract Terminated
We wish him well in his future at London Road.