There are any number of reference books with information about when and how the towns of Massachusetts were incorporated. One is Historical Data Relating to Counties, Cities, and Towns in Massachusetts, by Paul Guzzi, Secretary of the Commonwealth, published in 1975. My copy is well worn and loved, but at the moment it is hiding from me (I know that all the books come out at night and move themselves around). Since I am trying to compose an article about the settlement of Cape Cod and really need the resource, I turned to the Internet to find an online copy. The 1975 book is not available as an ebook, but the earlier edition, published in 1920, is available for download.
A case of no loss without some gain
I don’t think I have used this edition before and so I was particularly happy to discover that it arranges the towns by county (whereas the 1975 edition presents them all alphabetically). Thus I only had to make copies of four pages for my research – definitely a case of no loss without some gain.
The towns are arranged alphabetically within the counties, with the date they were first mentioned in the records or when they were incorporated. A third column gives detailed information about how the town was established, sections of it divided into other towns, parts of other towns that were annexed to it, boundaries established and re-established, etc. For example, Eastham’s name was established from the common land called “Nawsett” in 1651; 1678: “Eastham and purchasers on both sides to settle the bounds”; 1763: part established as Wellfleet; 1772: part of Harwich annexed; 1797: part of Eastham established as Orleans, and so forth.
A geographical Rubik’s Cube, so to speak
This is typical for all towns in old New England that began as large chunks of land and were gradually pared down into manageable towns, often with plenty of boundary disputes – in 1867 the bounds between Eastham and Orleans were re-established and part of each town annexed to the other town, for example.
These subtleties of town name and boundary changes can be mind numbing, but they are among those extremely important facts one needs to know when trying to track records – early Orleans records are with the Eastham records, Dennis was part of Yarmouth, Brewster was part of Harwich – a geographic Rubik’s Cube, so to speak.
I definitely recommend adding the 1920 edition of Historical Data for your e-library.
 The Commonwealth of Massachusetts, Historical Data relating to Counties, Cities and Towns in Massachusetts, prepared by the Secretary of the Commonwealth, Division of Public Records (Boston, 1920), download available through archive.org.