Zhang was born in Minhou, Fujian province in 1902. In 1919, he gained entrance to Tsinghua University. Graduating in 1923, he traveled to the United States where he began graduate studies at the University of Chicago in 1925, receiving his Ph.D. in 1929. Later that year, he returned to China and accepted a teaching post at the National Central University in Nanjing, China (now known as Nanjing University).
While pursuing his Ph.D. at the University of Chicago in 1928, Zhang discovered an asteroid which was given the provisional designation 1928 UF and later the number 1125. He named it "China" or "中華" (Zhōnghuá). However, this asteroid was "lost" as it was not observed beyond its initial appearance and a precise orbit could not be calculated (see lost asteroids). In 1957, while Zhang was director of the Purple Mountain Observatory in China, the observatory discovered a new asteroid. With his agreement the new object 1957 UN1 was reassigned the official designation 1125 China in place of the lost 1928 UF. However, in 1986, the newly discovered object 1986 QK1 was confirmed to be a rediscovery of the original 1928 UF, and this object was named 3789 Zhongguo ("中国" (Zhōngguó) is the Mandarin Chinese word for "China", in pinyin transliteration, whereas Zhōnghuá is a slightly older word for "China").
From 1941 to 1950, Zhang was head of the astronomy research institute at National Central University. Between 1946 and 1948, he returned to the United States to study variable stars. In 1950 Zhang became the director of the Purple Mountain Observatory, a position he held until 1984.
In 1955 he was elected a member, or academician, of the Chinese Academy of Sciences.
Zhang devoted himself to observing and calculating the orbits of minor planets and comets. Many asteroids were discovered at Purple Mountain Observatory, as well as three new comets: two periodic, 60P/Tsuchinshan (Tsuchinshan 2) and 62P/Tsuchinshan (Tsuchinshan 1), and one non-periodic, C/1977 V1. Tsuchinshan is the Wade-Giles transliteration corresponding to the pinyin Zĭjīn Shān, which is Mandarin Chinese for "Purple Mountain", named after the observatory he oversaw.