Joseph also went up from Galilee, out of the city of Nazareth, into Judea, to the city of David, which is called Bethlehem, because he was of the house and family of David;
And lineage - The “lineage” denotes that he was descended from David as his father or ancestor. In taking a Jewish census, families were kept distinct; hence, all went to the “place” where their family had resided. Joseph was of the “family” of David, and hence he went up to the city of David. It is not improbable that he might also have had a small paternal estate in Bethlehem that rendered his presence there more desirable.