Answer
France was a republic when Louis XVII was declared as king. This was because the French Revolution had overthrown the monarchy and established a new government. Louis XVII was the son of Louis XVI, who had been executed by the revolutionaries. Louis XVII was only a child at the time of his father's death, and he was never able to rule France as king.