Kern married Aline Freyenmuth in 1834, with whom he then relocated to
Frauenfeld, Thurgau's capital. during which time he helped to revise the canton's constitution, authored its criminal code, and sat on the education committee. Kern represented Thurgau at the
Tagsatzung, the federal council of delegates from each canton, in 1833–38, 1840–42, and 1845–48. In 1848 he was elected to the
National Council and held the presidency in 1850–1851, leaving the assembly in 1854; during this time he also served as a federal judge in the
Federal Supreme Court, where he was president in 1848–1850. He was a major contributor to the writing of the new
Swiss Constitution in 1848, the country's first federal constitution, and in 1854 he helped to establish the federal technical university
Eidgenössische Polytechnische Schule (now
ETH Zurich). From 1853 to 1857, he was also the director of the
Swiss Northeastern Railway company. Kern declined an 1849 appointment to a Swiss ambassadorship in
Vienna, but later represented Switzerland internationally. In 1856 he was sent to
Paris to partake in the mediation of the
Neuchâtel Crisis with
Napoleon III, and the next year he took up a formal post as Minister of Switzerland in Paris. During this time, he failed to mediate in the 1870–71
Franco-Prussian War, but provided assistance to Swiss nationals living in war-torn France. He resigned in 1882. == Later years ==