Mohamed Mahmood Alessa and Carlos Eduardo Almonte entered into a packaged plea deal in a Newark federal courtroom Thursday morning.
They admitted to conspiring to kill, maim and kidnap persons outside the United States by trying to join al-Shabab, a designated terrorist organization.
The two were arrested in June at New York's Kennedy Airport and admitted they were headed for Somalia.
The 21-year-old Alessa of North Bergen was born in the United States and is the son of Palestinian immigrants.
Twenty-four-year-old Almonte of Elmwood Park is a naturalized citizen who was born in the Dominican Republic. Both are Muslim.
They could face up to life in prison when sentenced in June.