France's sudden military intervention in its former colony Mali to contain Islamist groups which have gained control of the desert north marks a crossroads. Until now, the Socialist president, François Hollande, who had positioned himself as an anti-warmongerer with the early withdrawal of troops from Afghanistan, had been planning a more subtle role in west Africa.

Paris played a key part in the recent UN resolution to restore order in Mali. But the plan had been for west African forces to lead the way, starting in September. Europeans would meanwhile train the dishevelled and contested Malian army. In the corridors of the French foreign ministry, diplomats always maintained that France would not - indeed could not - lead on the frontline with troops. Paris was keen to shake off its former colonial mantle by keeping a low-key role.

But after a surprise push by the rebels, leaving the path open to the capital, Bamako, France suddenly stepped in with fighter-jets and ground troops. Hollande carefully explained to the nation that he had a legal international mandate to act, backed by the UN and a request for help from Mali's embattled president. The French defence minister called it "a war against terrorism". Mali risked disintegrating into a jihadist state that would be a major international threat. It was sold as the war France could not avoid.

Yet France remains aware of the baggage it carries in Africa. Since the end of colonial rule, the Élysée has been accused of pulling strings, sweetened with briefcases of petrodollars, propping up contested leaders to suit Paris's business interests in a shady system known as "Françafrique".

The horrors of Rwanda and the bitter taste left by Nicolas Sarkozy's 2007 speech in Dakar that "the African has never really entered into history" still cast a shadow. Hollande promised that era was over when he was elected.

France, the only European country still to have a permanent military presence in Africa with several major military bases, had sought to move on from its role as "gendarme" of the region. Weeks before the Mali intervention, Hollande conspicuously refused to come to the rescue of the incumbent leader in Central African Republic, another former colony.

Already commentators in France are saying Mali could transform Hollande's political image. Unpopular in the polls and accused by critics of dithering on the economy, Mali has shown Hollande in decisive mode. "If Sarkozy had Libya, Hollande will have Mali," said Le Parisien, referring to Sarkozy's personal investment against Gaddafi. But "Sarkozy's war", as Libya was termed, never boosted the former rightwing president's poll ratings and failed to get him re-elected.

Military intervention in Mali, likely to be drawn out, is not without risk for Hollande. He will probably be pictured greeting coffins draped in the tricolour flag. France's eight-month role in Libya saw no troops killed, but on the first day in Mali, a French helicopter was downed and its pilot died. Mali's rebels, who control an area larger than Afghanistan, are better armed and trained than thought, boasting state-of-the-art weaponry left over from the Libya conflict. Civilian casualties are a major factor. France has eight hostages held by al-Qaeda-linked groups in the region who are more vulnerable than ever. The terrorist risk level on French soil has been stepped up to maximum.

France's aim for the time being is to hold back the rebels while a joint West African force prepares the drive to win back the north. So far Hollande has enjoyed the traditional cross-party support for military action, bar a few sceptical voices such as the leftist Jean-Luc Melenchon. Dominique de Villepin, who led world opposition to the US-led Iraq war in 2003, warned that "war is not France" and pointed to the political mess left behind in places such as Iraq.

But most damaging of all, when parliament debates the action in Mali on Monday, the government faces difficult questions on two African fronts. As the Mali offensive began, Paris was shaken by a botched French bid to free one of its intelligence agents held for more than three years by Islamist militants in Somalia. After what seems like a major fiasco and intelligence failing, the hostage is presumed killed, another soldier is perhaps in enemy hands, and two soldiers are feared dead along with civilians.

As one French diplomat said last month of any action in Mali: "It would be heavy, onerous, not the peacekeeping we are used to elsewhere in Africa."