A Taliban suicide car bomber killed one American soldier and two Afghan civilians near a US military base shortly after the visiting US defence secretary left the facility in southern Afghanistan, officials said.
The attacker targeted a moving vehicle near the access gate to the military side of Kandahar's airport, according to Afghan defence ministry spokesman General Mohammad Zahir Azimi.
It was unclear whether the blast had anything to do with Leon Panetta's unannounced visit to Kandahar Airfield earlier on Thursday. The sprawling facility houses more than 20,000 service members from 20 countries and has more than 11,000 civilian contract workers.
Mr Panetta said one American soldier was killed and three others wounded. Gen Azimi said two Afghan civilians were killed and 14 wounded.
Taliban spokesman Qari Yousef Ahmadi claimed responsibility for the attack in an email, saying a suicide car bomber had targeted foreign military vehicles that were stopped near the gate of Kandahar Airfield.
Mr Panetta was at the air field for about three hours, receiving a briefing from US army Major General Robert Abrams, the region's top coalition commander. Mr Panetta also spoke to about 350 US troops and took questions from them before flying back to Kabul.
A US official said early indications were that the attacker did not breach the base's perimeter.
Earlier, Ahmad Javed Faisal, spokesman for the governor of Kandahar province, said the attack was carried out by a bomber on a motorcycle.