Sicily and Sardinia were lost, and, in the aftermath of the Mercenary Rebellion, Africa was too unstable for further expansion to be contemplated there, so Carthage turned her attention increasingly to her Spanish territories. In 238-237 Hamilcar Barca was sent at the head of an army to take charge of the province there, and the choice of such an experienced and aggressive commander for a region which does not appear to have faced a major threat can only mean that the objective was expansion. For the next nine years Hamilcar fought almost continuously, securing Punic control of the coastal strip of southern Spain and pushing up to the valley of the Guadalquivir, until he was killed in an ambush by a Celtiberian tribe known as the Oretani in 229, one tradition claiming that he deliberately sacrificed himself to save his young sons.20 He was succeeded in the command by his son-in-law and second-in-command, Hasdrubal, who continued the programme of expansion, achieving more through diplomacy than war, even marrying a Spanish princess to cement one alliance. The succession seems to have been first voted for by the army in Spain and subsequently approved by the authorities at Carthage. This was certainly the case when Hasdrubal was assassinated in 221 and the army, or at least its officers, gave the command to Hamilcar's eldest son, the 26-year-old Hannibal, a decision later ratified by the Popular Assembly in Carthage.21
The basic narrative of Punic expansion in Spain under the leadership of the Barcid family is straightforward and uncontroversial, even if our sources sometimes contradict each other on minor points, but many important questions remain unanswered. It is unclear how and why Hamilcar was given the Spanish command in the first place and to what extent his activities once there were supervised. One extreme view is to see this period as the triumph of the Popular Party in Carthage, Hamilcar the demagogue winning the support of the ordinary citizens wearied by the incompetence displayed by the old aristocracy during the war with Rome and the Mercenary Rebellion. This allowed him to secure an unlimited command in Spain with the freedom to wage war and enrich himself for his own purposes. There may be a few indications of political change at Carthage, since the Council of 104 seems far less prominent after this period, and the importance of the two annually elected suffetes may have increased.22 However, it must always be remembered that our evidence for the constitution and internal politics of Carthage is exceptionally poor. Most of our sources do portray the Barcid family as facing strong opposition from rivals who feared their growing power and from those who objected to their policies, but it is unclear how strong and consistent such opposition was.23 In one tradition Hamilcar used the booty from his Spanish campaigns both to secure the loyalty of his soldiers and to buy himself political support at home.24 It is equally possible to interpret the same evidence as showing Hamilcar as nothing more than a servant of the state, appointed with the general approval of the elite at Carthage.25 The truth may lie anywhere between the two extremes.
The Second Punic War began in Spain, making the activity of the Barcid family there in the years after the First War especially important, but our sources' awareness of this only makes it more difficult to understand what sort of regime they created, and how significant it was that the command was held exclusively by members of the family. It is not entirely clear whether the Carthaginians ratified the army's choice of leader because they felt that they were powerless to change this or because they approved of the decision. There may have been a practical benefit from this, since it was far easier for Spanish tribes and leaders to focus their loyalty on an individual general and his family than on a distant Carthage, emotions which the Romans would also later exploit. The activities of the Barcids in Spain may simply be seen as an effective way for the Carthaginian state to expand its territory there, allowing them more easily to exploit the resources of mineral wealth and military manpower. For other historians these years saw the creation of what was in effect a semi-independent principality ruled by the family for their own ends, the Barcid perhaps assuming the trappings of Hellenistic monarchs. Again, our evidence is utterly inadequate to resolve this debate. The same series of coins produced by mints in Punic Spain in this period have been interpreted as showing Hamilcar and Hasdrubal depicted as Hellenistic kings with divine associations, or simply as being images of deities.26 Hasdrubal certainly founded a major city called New Carthage (modern Cartagena), but whether this should be seen as the seat of provincial government or the capital of a semi-independent kingdom depends on the view taken of Barcid ambitions.