Other answers from our community:
John the Baptist was a contemporary of Jesus. He was the son of Elizabeth and Zacharias (Luke 1:5-7) and was conceived six months before Jesus. (Luke 1:39-56
John the Baptist was born 6 months before Jesus circa late March, early April 5 BC. He prepared the way for our Savior circa 25-27 AD and was beheaded shortly after the beginning of Jesus' ministry which began in 27 AD.
We know approximately when John the Baptist died, but there is
uncertainty about when he was born.
Luke 1:5-7 says that John was born just a few months before Jesus, but of course we do not really know when Jesus was born. The Gospels of Matthew and Luke are more or less in agreement that Jesus was born during the reign of King Herod the Great, who died in April 4 BCE, and Matthew implies that his birth was at least a few years before Herod died. In any case, many New Testament scholars question the account of John's birth, which only the author of Luke seems to have known.
We do know, from the Jewish historian Josephus, that John the Baptist died in 35 or 36 CE, because his execution occurred some time after Herod Antipas married Herodias in 34 CE and only shortly before Aretas of Nabatea invaded Galilee in 36 CE.