“Behold, the days are coming, declares the Lord, when I will raise up for David a righteous Branch, and he shall reign as king and deal wisely, and shall execute justice and righteousness in the land.” Jeremiah 23:5
The “righteous Branch” refers to the Messiah. The Jews knew the Messiah was coming and that He would come from the line of David. If someone claimed to be the Messiah, one way of checking was to make sure their family tree included David. If they were not of the line of David, they failed one of the 330 tests (prophecies) and could be scratched off the list of potential candidates. A score of less than 100% was an automatic failure.
In 2 Samuel 7:12-13, Nathan tells David about the Lord’s covenant with him, “When your days are fulfilled and you lie down with your fathers, I will raise up your offspring after you, who shall come from your body, and I will establish his kingdom. He shall build a house for my name, and I will establish the throne of his kingdom forever.” He not only said David’s “offspring,” but he simplified it by saying “from your body.” The promise was not vague. Verse 16 adds, “And your house and your kingdom shall be made sure forever before me. Your throne shall be established forever.” In both places, it is stated the kingdom would be forever. This happened by the Messiah.
God likes to make things clear. Therefore, He recorded both the genealogy of Joseph and Mary. Both families are from the line of David.
Matthew chapter 1 records the genealogy of Joseph. Verse 1 gives a great summary, “The book of the genealogy of Jesus Christ, the son of David, the son of Abraham.” Matthew then starts with Abraham (verse 2), goes to David (verse 6), and ends up with a great summation in Jesus, “and Jacob the father of Joseph the husband of Mary, of whom Jesus was born, who is called Christ” (verse 16).
Luke chapter 3 records the genealogy of Mary. This genealogy begins with Mary’s family (verse 23) and works backward to finally reach David (verse 31).
I imagine as a child, Jesus always did all the extra credit homework. In coming to Earth, He needed to fulfill some 330 prophecies to be considered the Messiah. One of those was to be from the line of David. He fulfilled it twice!
In Acts 13:22-23, Paul gives a history lesson saying, “And when he had removed him, he raised up David to be their king, of whom he testified and said, ‘I have found in David the son of Jesse a man after my heart, who will do all my will.’ Of this man’s offspring God has brought to Israel a Savior, Jesus, as he promised.”
Jesus is the Messiah. Jesus is the Savior!