Earlier on Saturday Rice met Zine El Abidine Ben Ali, the Tunisian president, in Tunis and later in the day met Abedelaziz Bouteflika, Algeria's president, in Algiers.
"We have talked about our strong interest in fighting terrorism, our counter-terrorism co-operation and I said to the president [Bouteflika] that I was very saddened at the loss of life of innocent Algerians in recent terror incidents," Rice told reporters earlier.
Fifty-five people died in three attacks - two car bombs and one suicide blast that killed 43 people - in a 48-hour period in Algeria in August.
Rice's route within Algeria was the subject of heightened security precautions, after the website of one armed Islamic group urged the north African branch of al-Qaeda to assassinate her during her tour.
Rice's visit is her first to the Maghreb region as secretary of state. The region has become of increasing strategic importance in terms of oil resources, illegal-emigration and the so-called "war on terror".
Rice said that the threat posed by armed groups in North Africa has become "even more salient in the recent months".
Throughout her tour, civil liberties groups have questioned Rice on human rights including reports alledging that Maghreb citizens held at Guantanamo Bay, the US prison facility in Cuba, have been known to disappear upon their return home.
US-based Human Rights Watch called on Rice to press the Algerian government on the well-being and status of former Guantanamo detainees.
Many prisoners have expressed fear that they will face abuse if sent to their native countries, according to rights groups who dismiss as worthless diplomatic assurances they will be treated humanely.
Rice said the US was co-ordinating with North African governments to empty Guantanamo.
"We would like to move as much of the population of Guantanamo out as soon as we possibly can," she said after a lengthy meeting with Bouteflika.
"We would like to, but we also have to remember that we have an obligation not to have dangerous people on the streets."
The "highlight" of Rice's Maghreb trip was on Friday, when she met Libya's Gaddafi, who for decades has been considered an international pariah by many Western countries.
She ignored the fifth Maghreb nation of Mauritania, amid US refusal to recognise the legitimacy of its leaders after a military coup there in August.