How did God punish Herod for what he did to John the Baptist?

A:

The Jewish historian Josephus said that Herod Antipas had John the Baptist killed because he disapproved of Antipas' marriage to his own brother's wife, who divorced her husband in order to marry Herod Antipas. The wedding took place in 34 CE and the execution of John would have been in 35 or 36 CE. The relevant text from Book 18 of Antiquities of the Jews:
"Now many people came in crowds to him, for they were greatly moved by his words. Herod, who feared that the great influence John had over the masses might put them into his power and enable him to raise a rebellion (for they seemed ready to do anything he should advise), thought it best to put him to death. In this way, he might prevent any mischief John might cause, and not bring himself into difficulties by sparing a man who might make him repent of it when it would be too late. Accordingly John was sent as a prisoner, out of Herod's suspicious temper, to Macherus, the castle I already mentioned, and was put to death."

King Aretas of the Nabateans attacked Herod Antipas in 36 CE because of the insult to his daughter whom Antipas had divorced in order to marry his brother's wife, leading the Jews to believe that this was God's way of punishing Antipas for the death of John the Baptist. This also means that the death of John was not long before the attack.