At the 2012 Australian Swimming Championships in Adelaide, To narrowly missed out on earning selection to compete at the 2012 Summer Olympics. He placed 4th in the 200m medley and 9th in the 100m freestyle, largely because 7 weeks earlier he had required an operation to remove his appendix. Nonetheless, To was selected to compete at the 2012 Oceania Swimming Championships. At the 2012 Oceania Swimming Championships in Nouméa, To won a total of 7 medals in a return to form. He won gold in the 100m freestyle, 200m freestyle, 200m medley, 4 × 100 m freestyle relay and 4 × 200 m freestyle relay, and silver in the 100m butterfly and 400m medley. At the 2012 FINA Swimming World Cup series, To claimed a big prize in winning the men's overall scoring on a total of 195 points. At the Dubai meet, he set a new Australian record for the 100m medley in 51.43. At the 2012 FINA World Swimming Championships (25 m) in Istanbul, To won silver in the 100m medley and bronze in the 4 × 100 m freestyle and medley relays. His time of 51.38 in the 100m medley was only 0.17 off the winning performance of American superstar Ryan Lochte, and set another Australian record in that event.