According to a Time.com article, Julius Caesar was kidnapped by pirates when he was 25.
He charmed them, telling his captors to double their ransom demand and joking about how he would punish them.
Is this story true?
Perhaps; but we will probably never know for sure.
The source for this story is "The Life of Julius Caesar" by the Greek historian Plutarch, who writes in the very beginning (this is going to be a long quote, but it gives you an idea of the colorfulness of the story):
First, when the pirates demanded a ransom of twenty talents, Caesar burst out laughing. They did not know, he said, who it was that they had captured, and he volunteered to pay fifty. Then, when he had sent his followers to the various cities in order to raise the money and was left with one friend and two servants among these Cilicians, about the most bloodthirsty people in the world, he treated them so highhandedly that, whenever he wanted to sleep, he would send to them and tell them to stop talking. For thirty-eight days, with the greatest unconcern, he joined in all their games and exercises, just as if he was their leader instead of their prisoner. He also wrote poems and speeches which he read aloud to them, and if they failed to admire his work, he would call them to their faces illiterate savages, and would often laughingly threaten to have them all hanged. They were much taken with this and attributed his freedom of speech to a kind of simplicity in his character or boyish playfulness.
However, the ransom arrived from Miletus and, as soon as he had paid it and been set free, he immediately manned some ships and set sail from the harbor of Miletus against the pirates. He found them still there, lying at anchor off the island, and he captured nearly all of them. He took their property as spoils of war and put the men themselves into the prison at Pergamon. He then went in person to [Marcus] Junius, the governorof Asia, thinking it proper that he, as praetor in charge of the province, should see to the punishment of the prisoners. Junius, however, cast longing eyes at the money, which came to a considerable sum, and kept saying that he needed time to look into the case.
Caesar paid no further attention to him. He went to Pergamon, took the pirates out of prison and crucified the lot of them, just as he had often told them he would do when he was on the island and they imagined that he was joking.
(You can also read a more classical translation)
Now, Plutarch is the source of a lot of the information we have about great men of ancient Greece and Rome. However, the venerable historian was born 90 years after Caesar's death, and perhaps 150 years after the purported events, when many details of Caesar's life have become legends and anecdotes, and might have lost some of their historic accuracy. There is also Suetonius' AD 121 "The Life of Julius Caesar", which gives a somewhat less enthusiastic account:
While crossing to Rhodes, after the winter season had already begun, he was taken by pirates near the island of Pharmacussa and remained in their custody for nearly forty days in a state of intense vexation, attended only by a single physician and two body-servants; for he had sent off his travelling companions and the rest of his attendants at the outset, to raise money for his ransom. Once he was set on shore on payment of fifty talents, he did not delay then and there to launch a fleet and pursue the departing pirates, and the moment they were in his power to inflict on them the punishment which he had often threatened when joking with them.
Here, JC has lost most of his panache, became vexed, and the doubling of the ransom is not mentioned. However, Suetonius might (or might not) have taken this story from Plutarch.
So - to sum up - there is an ancient source for this story, but we do not know whether it is reliable.