The men were captured within hours of the incident, which was called "carefully planned, organized and premeditated," by the Beijing police.
Police initially declined to comment on whether they thought it was a deliberate attack or an accident, but now they have declared it a terrorist attack.
Occupants of a Jeep that crashed through crowds and burst into flames included a man, his wife and his mother. The three died after their fuel caught fire.
Police found gasoline containers, metal rods and two machetes in the car. They also found a flag associated with religious extremists.
The five suspects still alive were arrested in a night raid 10 hours after the incident and detained after police found long knives and jihadi flags in the place they were staying.
"After the preliminary investigation [the suspects] confessed that they knew the criminals, and conspired [with them] and carried out the terror attack, and said they did not expect that in only 10 hours the police would capture them," Xinhua media said.
Celebrity Couples of 2014 [PHOTOS]