In 1842 he moved to Java, working in a botanical garden, and on small government-financed scientific expeditions. He returned to Switzerland in 1848, but came back to Java in 1855 with his wife and two children.