In the Gospel of Luke, after the Sanhedrin trial of Jesus, the Court elders ask Pontius Pilate to judge and condemn Jesus in 23:2, accusing Jesus of making false claims of being a king. While questioning Jesus about the claim of being the King of the Jews, Pilate realizes that Jesus is a Galilean and therefore under Herod's jurisdiction. Since Herod already happened to be in Jerusalem at that time, Pilate decides to send Jesus to Herod to be tried.
Herod Antipas (the same man who had previously ordered the death of John the Baptist and, according to some Pharisees, had plotted to had Jesus killed as well) had wanted to see Jesus for a long time, hoping to observe one of the miracles of Jesus. However, Jesus says nothing in response to Herod's questions, or the vehement accusations of the chief priests and the scribes.
Herod and his soldiers mock Jesus, put a gorgeous robe on him, as the King of the Jews, and send him back to Pilate. That day, Herod and Pilate, who had previously been enemies, become friends.