Cao was admitted to and started his undergraduate education at the Special Class for the Gifted Young of the University of Science and Technology of China in 2010. He traveled to the United States and studied at the University of Michigan as an undergraduate exchange student from 2012 to 2013. In 2014, Cao graduated from the University of Science and Technology of China, receiving a Bachelor of Science with a major in physics. He went to the Massachusetts Institute of Technology in 2014 and received a Doctor of Philosophy in electrical engineering in 2020.