Asked by the judge what kind of operations, he responded: "Suicide-bombing operations."
'War against Islam'
"I personally believed that conducting an operation in the United States would be the best way to end the war [in Afghanistan]," he said.
Ahmedzay quoted heavily from the Quran during his plea and urged Americans to "stop supporting the war against Islam".
"I'm thankful for myself that I didn't harm anyone, but I feel someone else will do the same thing"
"I'm thankful for myself that I didn't harm anyone, but I feel someone else will do the same thing," he said.
Michael Marinaccio, Ahmedzay's lawyer, declined to say whether his client was co-operating with the investigation, but added that by agreeing to plead guilty, "there's a potential benefit to him".
Ahmedzay faces a possible life term in jail when he is sentenced on July 30.
Zazi, a Colorado airport shuttle driver, admitted this year that he tested bomb-making materials in a Denver suburb before travelling by car to New York with the intent of attacking the subway system.
Ahmedzay and the third suspect, Adis Medunjanin, had previously pleaded not guilty to charges that they sought to join Zazi in what prosecutors described as three "co-ordinated suicide bombing attacks" on Manhattan subway lines.
Robert Gottlieb, Medunjanin's lawyer, said on Friday that his client intended to go to trial.
Officials have said a fourth suspect is in custody in Pakistan but have given no other details about him.
Medunjanin, who is originally from Bosnia, and Ahmedzay, who was born in Afghanistan, are US citizens. They and Zazi, an Afghan immigrant, attended Flushing High School in New York City.
Ahmedzay said on Friday that al-Qaeda leadership encouraged the men to target "well-known structures" in New York to cause "maximum casualties".
|Ahmedzay said al-Qaeda encouraged them to target 'well-known structures' [Reuters]
He said they also decided that the attack should occur during the Muslim fasting month of Ramadan, between August 22 and September 20 last year.
Prosecutors said the three settled on the subways after Zazi determined he could only make enough explosives for a smaller-scale attack in time for Ramadan, and decided it would happen September 14, 15 or 16.
The plot was disrupted in early September when police officials stopped Zazi's car as it entered New York.
Last month, an Afghanistan-born imam linked to the suspects pleaded guilty to lying to the FBI when asked about the men. He was sentenced to time served and ordered to leave the US.
Eric Holder, the US attorney-general, said on Friday that the plot "makes clear we face a continued threat from al-Qaeda and its affiliates overseas".
"With three guilty pleas already and the investigation continuing, this prosecution underscores the importance of using every tool we have available to both disrupt plots against our nation and hold suspected terrorists accountable," he said.