Jesus' genealogy can be found at two places in the Bible.
Matthew's gospel (Mat 1:2-16) starts with Abraham and lists his descendants all the way down to Jesus. There are 41 generations in total, divided into 3 sections as follows:
- Abraham – David (from Abraham to David)
- David – Josias (from David until the carrying away to Babylon
- Jechonias – Jesus (from the carrying away into Babylon unto Christ)
Each section contains 14 generations. Note that David is counted twice: once at the end of the first section, then once again at the beginning of the second section. This explains how 41 generations are divided equally into three. See Mat 1:17 for further explanation.
Luke’s gospel (Luk 3:23-38) starts with Jesus and follows his line up until God. There are 77 generations mentioned in total.