Special Agent Jaime Zapata was killed and a second agent injured Tuesday when gunmen attacked their blue Suburban vehicle as they drove through the state of San Luis Potosi.
Zapata was on assignment to the ICE attache in Mexico City from his post in Laredo, Texas, according to The Associated Press.
Authorities have not released the name of the other agent.
"This is a difficult time for ICE and especially for the families and loved ones of our agents," ICE Director John Morton said, according to the Los Angeles Times.
Zapata was a native of Brownsville, Texas, the AP said. He graduated from the University of Texas at Brownsville in 2005 and joined the ICE in 2006. He had served on the Human Smuggling and Trafficking Unit and the Border Enforcement Security Task Force. Authorities did not release his age.
The attack was a rare assault on U.S. officials working in Mexico. The U.S. has provided millions of dollars in aid to President Felipe Calderon and the Mexican government as they battle heavily armed drug-smuggling gangs.
"No [U.S.] agents have actually been specifically targeted yet during the [Calderon] administration," Malcolm Beith, author of the "The Last Narco," told The Christian Science Monitor. "If they were targeted intentionally, then it's a definite escalation."
The two men were driving on a four-lane federal highway from Mexico City to the northern city of Monterrey. They were not traveling as part of any investigation, the AP said.
The agents were stopped at what may have appeared to be a military roadblock. When they stopped, at least one gunman opened fire on the vehicle. The Mexican military says it has no checkpoints in the area.
The Mexican government issued a statement "energetically condemning this grave act of violence," the Los Angeles Times reported.
It isn't yet clear if the killers knew that the two men were ICE agents.
The ICE has between 25 and 30 agents working in Mexico. They investigate problems such as arms smuggling and human trafficking. The agency also trains Mexican law enforcement officials.
Mexican drug violence has spread from border cities such as Ciudad Juarez to engulf previously peaceful locations such as Monterrey, an industrial center, and tourist hot spot Taxco.
"This worries us very much because this type of incident doesn't happen very often in San Luis Potosi," a police spokesman said, according to the AP.
Tuesday's killing will increase pressure on Mexican authorities to bring the killers to justice, according to George Grayson, a Mexico expert at the College of William and Mary in Williamsburg, Va.
"You start killing U.S. officials, and that really turns up the heat," Grayson said, according to The Christian Science Monitor. "There's going to be great pressure on the Mexican government to find out who was behind this killing, enormous pressure."