It was the capital of Illinois from 1819 to 1839 .
From 1819 to 1839 it served as the state capital of Illinois .