KABUL, Afghanistan — All French combat forces will pull out of Afghanistan by the end of the year, France’s new president said in Kabul Friday, but some trainers will remain to help Afghanistan’s nascent security forces.

Francois Hollande said that France’s troops have carried out their mission in Afghanistan and it is time for them to leave, an early pullout that will be coordinated with the United States and other allies.

“There will be no combat troops” after the end of the year, Hollande said during a joint news conference with Afghan President Hamid Karzai.

Hollande flew to Afghanistan to meet with troops and to discuss plans with Karzai to withdraw French combat troops more than a year earlier than scheduled. His visit was not announced ahead of time for security reasons, and he was expected to depart shortly after the news conference.

Hollande said that France will pull its 2,000 combat troops, out of a total of 3,300, out by the end of the year. Some would stay behind to help send military equipment back to France, and others would help train the Afghan army and police. He did not provide a breakdown for the roles of the 1,300 soldiers who will remain past 2012 or how long they would stay.

Hollande said that continued cooperation was discussed over lunch with Karzai “because there will continue to be trainers who will work with (Afghan) soldiers and police.”

He said French equipment would be taken out by ground routes, but did not say which ones.

Pakistan closed overland supply routes to Afghanistan for NATO after a U.S. attack on the Pakistani side of the border killed 24 Pakistani soldiers last November. The decision has forced NATO to use a far more costly route running through the north.

Talks to reopen the routes have been stuck over fees — Pakistan is demanding $5,000 per truck. The fee had been $250 a truck before the attack, and the United States, which is handling the talks, has countered with an offer of $500.

France has signed an agreement with Afghanistan that calls for cooperation after 2014. Other countries, including the United States, have signed similar accords.

“We want France to have a presence in Afghanistan differently from how it did in the past,” Hollande said. France wants to be “useful in a different way,” in economic and cultural matters, he said.

During an earlier meeting with French troops at a base in the Nijrab district of the eastern Kapisa province, Hollande said “several reasons justify this decision to withdraw our combat troops from Afghanistan.”

“The time for Afghan sovereignty has come,” he said. “The terrorist threat that targeted our territory, while it hasn’t totally disappeared, is in part lessened.”

Another reason “is that, simply, you have carried out your mission.”

“Thank you for what you have accomplished for France, what you are doing for Afghanistan,” Hollande told the troops before flying to Kabul to meet Karzai.

Hollande announced plans at a NATO summit this week to pull out French troops by the end of the year, well ahead of the alliance’s 2014 withdrawal date.

Reflecting increasing French disillusionment with the war, Hollande’s conservative predecessor, Nicolas Sarkozy, had pledged to withdraw all troops by the end of 2013. Hollande, elected president this month, made a more immediate pullout a pillar of his campaign.

Tension over Hollande’s pledge to end his country’s combat mission two years early dominated the NATO summit in Chicago, unleashing fears of a domino effect of other allies withdrawing early. France is the fourth largest troops contributor after the United States, Britain and Germany.

President Barack Obama last year decided to pull out 33,000 U.S. combat troops by September.

Gen. John Allen, the top U.S. and NATO commander in Afghanistan, said this week that on Sept. 30 there will be 68,000 U.S. and about 40,000 other coalition forces in Afghanistan — compared to more than 130,000 last year.

The coalition has started handing over security control to Afghan army and police in areas home to 75 percent of the population, with a goal of putting them in the lead for all the country by mid-2013. NATO and other foreign forces would then be in a support role for the 352,000-strong Afghan National Security Forces.

Most foreign combat troops will have left Afghanistan by the end of 2014, when Afghanistan will take complete control for security around the country.

Kapisa, where French forces are based, is one of the areas now being transferred to Afghan control. Ashraf Ghani, head of a commission overseeing the transition, said earlier this month that “the risks in Kapisa are containable and within our capability.”

“Between now and the end of the year, the Afghan army will take control of the zones protected by our forces,” Hollande said. The transition will be carried out “intelligently and with complete and friendly cooperation with the Afghan authorities”

French Defense Minister Jean-Yves Le Drian and Foreign Minister Laurent Fabius are also in Kabul with Hollande.

Despite assurances from the Afghan government and the U.S.-led coalition that the situation in Afghanistan has been improving, violence persists around the country.

Afghan officials said that three explosions in three cities of southern Afghanistan on Friday killed three and wounded at least nine others.

Fareed Ayal, a spokesman for the police in Uruzgan province, said a police vehicle hit a roadside mine in Chora district, killing a police inspector and wounding two other policeman.

Daud Ahmadi, a spokesman in Helmand province, said a roadside bomb struck a bus in Gereskh district. Two civilians died and four others were wounded. He said the bomb was planted near a NATO supply site in an apparent attempt to target foreign troops.

In Kandahar province, police chief Gen. Abdul Razaq said a suicide bomber on a motorcycle blew himself up in Spin Boldak district, wounding a border policeman and two civilians.

——— Associated Press writers Mirwais Khan in Kandahar, and Angela Charlton and Sarah DiLorenzo in Paris, contributed to this report.