The territory of the present United States state of New Hampshire has a colonial history dating back to the 1620s. This history is significantly bound to that of the neighboring Massachusetts, whose colonial precursors either claimed the New Hampshire territory, or shared governors with it. First settled in the 1620s under a land grant to John Mason, the colony consisted of a small number of settlements near the seacoast before growing further inland in the 18th century. Mason died in 1635, and the colonists appropriated a number of his holdings. Thomas Roberts served as the last Colonial Governor of the Dover Colony before it became part of the Massachusetts Bay Colony. In 1641 the New Hampshire colonists agreed to be ruled by Massachusetts Bay Colony, which also claimed the territory. Massachusetts governed the New Hampshire settlements until 1680, when it became the royally chartered Province of New Hampshire. In 1686 the territory became part of the Dominion of New England, which was effectively disbanded in 1689 following the 1688 Glorious Revolution in England. After an interregnum under "de facto" rule from Massachusetts, Samuel Allen, who had acquired the Mason land claims, became governor. From 1699 to 1741 the governorships of New Hampshire and the Province of Massachusetts Bay were shared.