Hamilcar Barca rose to fame during the final years of the First Punic War, which the Romans and Carthaginians had started in 264. After heavy fights, the war had ended in a stalemate. Rome had conquered several cities on Sicily (Messana, Acragas, and Panormus), but its possession of these towns was not safe as long as Carthage had a bridgehead in the very west of the island: Lilybaeum and Drepana (modern Marsala and Trapani). At the beginning of the 240s, the Romans had started to besiege these two strongholds, but their enemies had been able to reinforce their troops on Sicily. Rome had not yet decisively beaten the Carthaginians, who still were powerful at sea and employed blockade-runners.
In 249, the Roman consul Publius Claudius Pulcher had tried to tighten the blockade, and had attacked the Carthaginian navy at Drepana. However, he was defeated by his opponent, admiral Adherbal. Even worse, for the Romans, was that the other consul, Lucius Junius Pullus, had lost the remains of the Roman navy in a tempest. Still, he had been able to occupy Mount Eryx, east of Drepana, which meant that the two ports were now cut off from the rest of the island. The siege of the two ports could continue.
Yet, both parties were exhausted. Rome was not able to build a new fleet, and Carthage concentrated on warfare against rebellious nomadic tribes in the interior, where Hanno the Great was successful. In retrospect, we can say that Carthage missed a chance to bring the war to an end: now that the Roman navy was annihilated, the Carthaginians could strike anywhere, and it is likely that after a recapture of Panormus, Rome would have been forced to come to terms. On the other hand, continued naval actions were expensive, and even wealthy Carthage was running short of money, because the nomadic tribes (which had been unleashed when the Romans had invaded Africa in 256) were really dangerous. Winning the war in the interior may have been a necessary first to finance the less threatening war on Sicily.
The impasse came to an end when Hamilcar Barca arrived on Sicily in 246. In the preceding year, he had raided the Italian coast; now, he struck in the rear of the Roman lines, and made a landing west of Panormus, where he occupied a mountain called Heirkte. For three years, he was able to attack Roman forces, ravaging the countryside, fight many skirmishes, and make naval raids as far away as Cumae and Catana. In 244, he suddenly attacked the Roman fortifications on Mount Eryx, and occupied a part of it, but was unable to raise the siege of nearby Drepana. Here, he was to stay for some time, besieging the besiegers.
In Carthage, Hamilcar was a popular, charismatic war hero who lived up to his family name: Bârâq means "lightning" (compare the Hellenistic royal title with the same meaning, Keraunos). But in the end, his actions did not really change the strategic positions of the two opposing sides. The siege of the two cities continued, the Romans slowly came closer to their objects, and Carthage was unable to prevent it. Hamilcar could not prevent it either.
Still, the cities had not been captured and blockade runners continued to reinforce the two strongholds. The Romans realized that the war had to be decided at sea, and built a new fleet. In the summer of 242, two hundred ships sailed to Drepana under consul Gaius Lutatius Catulus. The initial attack failed, but as provisions were running out in the city, the Carthaginians were forced to send reinforcements. In March 241, their fleet was ready. Its commander Hanno sailed to the east, but was defeated. The two besieged cities were now doomed.
The Carthaginian Senate, which did not want to commit itself to the surrender, asked Hamilcar to negotiate a peace treaty, and he left this dubious honor to Gesco, the commander of Lilybaeum.
He negotiated a fair deal: Sicily was to be Roman, Carthage was not to attack Syracuse (a Roman ally) and had to return all POWs, and it had to pay twenty installments of 110 talents. Unfortunately, the People's Assembly at Rome did not accept this, and the terms were tightened: Carthage lost some additional islands, 1000 talents had to be paid at once, and for the next ten years, Carthage would have to pay 220 talents. This was the end of the war.
The Carthaginian troops now returned to their homeland. Many of them had not received their pay for months, and they revolted. It was a motley crew of Greeks, Spanish, Balearic Islanders, Gauls, and Libyans that now they marched on Tunis, commanded by a former Italian slave named Spendius and a Libyan named Matho. Again, the Carthaginian Senate refused to take responsibility for negotiations; and again, Gesco was chosen to do the dirty work. When he visited the rebels, they tortured him to death.
The revolt of the mercenaries provoked other rebellions, and Carthage was seriously weakened. Only Utica and Hippo Diarrhytus remained loyal, and the desperate Carthaginians sent out an army, commanded by Hanno the Great, which failed to raise the siege of Utica. Now, Hamilcar Barca was appointed as second general, and he had more success, defeated the mercenaries at the Bagradas river, and pursued Spendius. He tried to end the war by a show of leniency, but Spendius ordered the execution of many POWs, after which the war became increasingly cruel. In the meantime, Utica and Hippo fell, and the mercenaries marched on Carthage, which they could not capture because they did not control the sea.
Hamilcar, who had defeated Spendius, was made sole commander, and tried to reach two war aims at once: to raise the siege of Carthage and reconquer Tunis. However, Matho was able to prevent the former, and Hamilcar had to give up the latter (239). In the winter, the Carthaginians built a new army. Hanno and Hamilcar decided to cooperate, and in the spring, they attacked. Matho was slowly repelled to the south, to Lepcis Minor. Here, the two armies finally met in battle, and Matho was defeated.
The Romans had kindly supported the Carthaginian war effort against the mercenaries, but when the war was over, Rome unexpectedly snatched away the Carthaginian province of Sardinia. It was not entirely without justification: the peace treaty was vague about the islands that Carthage had to hand over to Rome, and the mercenaries who occupied Sardinia were understandably afraid of the Carthaginians. So, the Sardinian garrison appealed to Rome, which bluntly took the island and declared war upon Carthage when it made protests. When the city sued for peace, the Romans were willing to grant it, provided that Carthage surrendered Sardinia and Corsica, and paid 1200 talents of silver.
Hamilcar Barca and Hanno the Great now understood that the future of Carthage was no longer at sea. Hanno preferred expansion in Africa, whereas Hamilcar was given the command in Iberia. His main ally was his son-in-law, Hasdrubal the Fair, who had great influence in the Carthaginian political arena. It is often said that Hasdrubal and Hamilcar applied more popular politics, whereas Hanno tended to favor the landed interest.
In 237, Hasdrubal and Hamilcar went to Gades (Cádiz), and embarked upon a campaign of conquest in Iberia. In their army were Numidian cavalrymen, who were loyal because their commander Naravas was betrothed to a daughter of Hamilcar. There was much to be won in Andalusia, which has silver mines and is extremely fertile. Besides: armies could be trained, far away from Roman spies. It is possible that Hamilcar was already dreaming of renewed war against the treacherous Romans. Although Hasdrubal later returned to Africa, he continued to support the war, especially when silver and other booty started to arrive.
It is hard to reconstruct the conquest of Iberia, but it seems that the plain of the Guadalquivir was the first to be conquered, and that at a slightly later stage, the Carthaginians founded a new capital, called White Promontory (Leuke Akra), probably Alicante. In 231, Hamilcar received a Roman embassy, which received the famous reply that the Carthaginians were not fighting against Roman allies, but trying to get the money to pay the Roman indemnity. Rome was content with this answer and decided not to interfere.
In 229, Hamilcar tried to capture the port of Helike (modern Elche), but the town received native reinforcements, and Hamilcar had to give up the siege. During the retreat, he drowned.
He was succeeded by Hasdrubal the Fair. When he died in 221, Hamilcar's son Hannibal Barca was appointed as general of the Spanish army. In 218, he provoked the war with Rome. His brothers Hasdrubal Barca and Mago Barca were important commanders too, and it is not exaggerated to say that the Second Punic War was only made possible by Hamilcar, who had given Carthage three excellent generals and a rich power base.