Let's get the raw facts of the Punic Wars out first. Rome was young and controlled much, but by no means all, of Italy and Sicily. The Etruscans and Gauls were still disputing Roman rule, and there were regular battles as Rome tried to assert power over those lands. The Greeks still had footholds around the Rhone river, a small colony in Iberia (now Spain) and a colony at Syracuse. The Carthaginians controlled north Africa, some of Sicily, Sardinia, much of Corsica, the Balearic Islands and bits of Iberia. The Carthaginians were a sea power. Their Quinqueremes were the most powerful ships in existence. No one challenged the Carthaginian fleets. The Romans were a land power, their legions were all but unbeatable in a pitched battle (due more to their discipline and solid ranks than individual skill).
It was only a matter of time before Rome and Carthage would come into conflict. They both competed for land and trade around the same sea. The conflict started around 270 BCE. Rome decided that Carthaginian control of Sicily was too close and that Rome needed to control Sicily as a buffer from nearby Carthage. They filtered their troops in across the straits from Italy and started a lengthy land war in Sicily.

About the map: this was taken from H.G Wells The Outline of History, published in 1921. This is one of the best guides to the history of the planet you will ever find (even though it is slightly dated). In two volumes, Wells covers all of history from the first life on the planet to about 1900. The "JFH" initials in the bottom-right refer to JF Horrabin, Wells' illustrator. I've taken his map, colored it in and moved it a few decades in time.
It's worth noting that religion plays a major role in this story. Carthage worshipped the god Baal, a frightening God associated with mountain-top power and lightning bolts whom they inherited from their Canaanite and Phoenician progenitors. It hasn't been definitively proven, but it seems extremely likely that they sacrificed their first male sons to Baal, around the age of four to six years old. In the Stanford lectures, Dr Hunt makes the connection between Baal and the Beelzebub mentioned in the Bible. Beelzebub means "lord of the flies" and it's likely, Dr Hunt asserts, that the rotting stench of all those burned children caused the status of Baal who watched over the sacrifices to be covered with flies. The Carthaginians took their religion very seriously. Dr Hunt goes so far as to speculate that Hannibal's choice to go through the Alps may have been influenced by the fact that the mountain tops were the natural home of this God. More on this later.
Hannibal's father, Hamilcar, was a Carthaginian general during the First Punic War, which was mostly fought in Sicily. He led a large guerilla force that maneuvered through the Sicilian landscape and harassed the Romans at every turn. Some of the battles were large, some were small, but Hamilcar's generalship was consistently excellent.
In individual courage indeed the Romans were far superior on the whole, but the general to whom the palm must be given both for daring and for genius is Hamilcar called Barcas, the actual father of that Hannibal who afterwards made war on the Romans.
Polybius, Book I, 64
The Romans took the prize for tenacity, however. Being unable to force a decisive result on land, they took to sea. Their first efforts were not good. The Romans had no seafaring tradition and they were slaughtered. They tried again. This time, they paid insufficient heed to the weather and had two whole fleets wiped out by a storm. They tried again and again. After losing hundreds and hundreds of ships, they finally managed to turn it around and beat the Carthaginians (very badly) at their own game.
The shock of a sound defeat at sea shook Carthage to the core. They surrendered and told Hamilcar to dicker terms with the Romans. This angered Hamilcar considerably, since he hadn't lost any major engagements with the Romans over the whole course of the war. He wanted to continue the war, but the Senate disagreed (I'm going to refer to them as the Carthaginian Senate, even though it wasn't a Senate in quite the way the Roman Senate was – "City Fathers" or "Council of Elders" might be better terms). No doubt this fueled his hatred of Rome even more. Carthage ended up having to pay a crippling tribute to Rome and give up its dominance of the sea. Thus Carthage lost the First Punic War.
Hamilcar then had to clear up a violent uprising of Carthage's mercenary troops. The Senate stupidly tried to cheat them on their pay for the war (they were broke after paying off Rome) and the mercenaries decided they would force the issue. In a war that was incredibly barbaric, with no terms or quarter on either side, Hamilcar smashed the uprising and scattered the surviving mercenaries to the winds.
This war had lasted for three years and four months, and it far excelled all wars we know of in cruelty and defiance of principle.
Polybius, Book I, 88
Since Iberia (present day Spain) wasn't part of the treaty Carthage signed with Rome and Carthage already had a colony there, Hamilcar decided to use his leadership to expand Carthaginian hegemony there. Hamilcar departed for Iberia (taking his sons with him) to build up the empire (Hamilcar referred to his three sons as the "lion cubs I am raising against Rome"). Hamilcar was successful in his work, building a good power base in Iberia and sending gold back to Carthage. He was killed from ambush, however, and command went to his son-in-law Hasdrubal. This lasted eight years, until Hasdrubal was killed by a Celtic assassin. The troops then wanted Hannibal to command them and they petitioned the Senate for this. Hannibal had been a favorite of the troops from the beginning. They saw him as a chip off the old block, a reincarnation of their venerable leader Hamilcar and Hannibal had already distinguished himself with smaller commands during Hasdrubal's leadership.
The Senate finally agreed and Hannibal put into effect the plan he had been born and sworn to carry out. No one knows where the plan to cross the alps and kick off the war in Rome's back yard came from. Personally, I think Hannibal and his father and the other sons discussed it for years: Hannibal would never have set out with an army of 100,000 men to cross the alps if he hadn't known in advance that it could be done and it would have taken years to gather the intelligence about the difficulties and limitations of the crossing.
The Second Punic War actually started before Hannibal even set foot on Roman soil. First, he attacked Sargentum, a very rich town in Spain (now called Segunto, you can still see the ruins of the city walls on Google Maps here). Hannibal besieged Sargentum for eight months before the city fell and when it did, it was a bloodbath. It was, however, an incredibly smart move on Hannibal's part. While Sargentum was an ally of Rome, it hadn't been last time Carthage signed a treaty with the Romans, so Hannibal had plausible deniability on that front (of course, Rome hadn't exactly followed the last treaty, either). As a military leader, I think Hannibal was smart enough to see that his new army needed to learn to work together and they needed a good, solid victory (with lots of spoils in the form of women, slaves and minor booty) to get them off on the right foot. His army would now be blooded and experienced at working together. The enormous spoils of precious metals from Sargentum would finance his expedition over the Alps. In addition, Hannibal would send a large amount of booty back to Carthage to guarantee that, unlike his father, he would enjoy the benevolence of that body. Hannibal also won the admiration of his new recruits by sharing all the danger and even taking a spear through the thigh during the battle. Fat from the takings, he went back and wintered in Cartagena, getting everything ready for tackling the Alps the next year.
Hannibal was able to cross the alps (much more on that later), but lost as much as half of his army in the process (historians seem to disagree on the actual number). He came down from the alps in the rich Po river valley, near the current city of Turin. I want to keep this brief, so I won't go into the details (try this for a more detailed account), but Hannibal preceded to do something nearly impossible: for fifteen years he rampaged up and down the Italian boot plundering at will. The four times that Rome would stand up and fight a pitched battle, Hannibal whipped them badly. They learned to harass him rather than fight him. How do you hold an army of 20,000 to 40,000 men together for a decade and a half in a hostile land without any other source of supply than your own wits? Can you imagine how much food and water 20,000 fighting men consume in a single day? (answer: at three pounds each, that's 30 tones of food per day to keep the army marching – almost 11,000 tones per year). What Hannibal did seems impossible, logistically. But not only did he survive, it's estimated that Hannibal and his army killed over 200,000 Romans in battle over that 15 year period.
Scipio (after his later victories in Africa, called Scipio Africanus) grew up at war with Hannibal. His father was wounded in the first major battle Hannibal fought in the Po Valley and Scipio rose in rank as he learned and became experienced. In 203 BC, he was given command of a Roman army and sent to Africa. The idea was to lure Hannibal out of Italy in defense of his homeland (the Romans weren't dense, they didn't need fifteen years to think of this, they had tried it before without success). Before the decisive battle, Hannibal and Scipio met to negotiate. Although Scipio was an admirer of Hannibal, he couldn't bring himself to trust the Carthagenian leadership (Romans had always held that Carthaginians were untrustworthy). In the end, at the Battle of Zama, Hannibal was forced (by his Senate) to go into battle with a decidedly inferior force, including thousands of untrained African draftees. The battle was vicious, but this time it was Scipio with the clever ideas and Hannibal's army was routed. As a sign of his respect, Scipio Africanus allowed Hannibal to escape and go on to lobby the Carthaginian Senate for peace. Eventually a very expensive peace was agreed to that had Carthage paying Rome a war indemnity of 10,000 talents of silver (over 660,000 pounds – call it $170M in today's money, over a pound of silver from each Carthaginian citizen) and giving up Iberia as a colony. Thus ended the Second Punic War.
There is considerable debate about why Hannibal didn't attack Rome itself after Cannae. Rome was on its knees at that point, so why not finish the job? I don't understand why this is a debate. Hannibal's strategy had always been to harass Rome and show Rome's allies that Hannibal would be a better friend than Rome. He wasn't in any way prepared for the incredibly difficult job of besieging Rome. As Rumsfeld famously said, "You go to war with the army you have---not the army you might want or wish to have at a later time." Hannibal would never have an army capable of besieging Rome, his only option was a strategy of stripping Rome of enough allies that their fear would cause them to sue for peace.
Hannibal went on to become a serious Carthaginian statesman, carrying out a series of political reforms and reducing corruption in the bureaucracy. Fourteen years later, however, the Roman Senate woke up and demanded his head. Hannibal avoided the issue by going into voluntary exile. He would live on for another dozen years serving as a military advisor to one potentate or another (at one point, he advises Prusias I of Bithynia's navy to fill earthen jars with poisonous snakes – when the enemy's boats drew near they were to hurl the jars into their boats where they would break open and serve as a prequel to the movie Snakes on a Plane). Through all these years, Rome stayed on his tail. Roman agents finally caught up with him in Asia Minor and he took poison to avoid capture at the age of 65.
For generations, Roman mothers would frighten unruly children by warning them that "Hannibal is at the gates!"
Even fifty years later, after Hannibal was dead and Rome had already beaten them twice, Rome was still afraid of Carthage. So afraid, in fact, that they used a pretense to start the Third Punic War (this was urged for years in Rome by Cato the elder –by this time a bitter old man who wasn't even liked by his own family – who ended every speech he gave in Senate about any topic with the phrase Carthago delenda est - "Carthage must be destroyed"). This war was on a smaller scale and most of it was a siege of Carthage, which was a city of about 700,000 at the time. After a lengthy siege, a battle and a burning of the city, only 50,000 Carthaginians survived and they were sold into slavery by the Romans. Effectively a genocide, the Third Punic War left no need for a fourth. The Romans burned the city, knocked down all of its stone walls and buildings and ruined the harbor. There is a story that they even salted the earth around the city, but it's probably not true since Julius Caesar would build a Roman city of Carthage on the same spot a hundred years later. North Africa would go on to become a major breadbasket for Rome's growing empire.
The Punic Wars set Rome on track to become the leading world power, but they were as cruel and vicious as any wars ever fought.
Note: this entry is part of a series called "Hannibal",
which contains the following entries:
Hannibal Studies
The Punic Wars
Hannibal and Rome
Hannibal in the Alps
Greatest General of All Time?