The cantref is an early Welsh administrative district, roughly similar in function to the English 'hundred'. The term is made up of two parts. Can or cant comes from the term for a hundred. Second is 'tref' a much less distinct term which might mean a house, settlement, or even a town. Thus the compound term 'cantref' generally meant the smallest type of settlement.
In Welsh history the cantref was made up of a number of commotes (cymydau), though cantrefi (the plural of cantref in Welsh) was the original division and the commote a later subdivision. Most cantrefi were divided into several commotes, usually 2 or 3, but as many as 7 for the largest.
Each cantref traditionally had its own court, and the boundaries between cantrefs often coincided with areas of distinct Welsh dialects, or even kingdoms. The court was usually administered by thew most powerful landowners within each cantref. The legal function of cantrefs was later taken over by commotes.