The massacre happened at a Walmart store near the Cielo Vista Mall, a few miles from the US-Mexican border.
The mall was full of shoppers buying back-to-school supplies at the time of the attack.
A 21-year-old man is in custody. Police said the suspect was a resident of the Dallas-area city of Allen, about 650 miles (1,046km) east of El Paso.
He has been named by US media as Patrick Crusius.
CCTV images said to be of the gunman and broadcast on US media show a man in a dark T-shirt wearing ear protectors and brandishing an assault-style rifle.
The victims have not yet been named. However, Mexico's President Manuel Lopez Obrador said three Mexicans had been killed, Reuters news agency reports.
The attack came less than a week after a teenage gunman killed three people at a California food festival. The Texas shooting has been dubbed the eighth deadliest in modern US history.
The police and FBI are investigating whether an anonymous white nationalist "manifesto", shared on an online forum, was written by the gunman. The document says the attack was targeted at the local Hispanic community.
FBI says more investigative work was needed before determining whether there was a possible hate crime.
The latest mass shooting in the United States has led to an outpouring of sympathy, but also led to fresh calls for gun control.
Subscribe to Bishop Ikedi Blog
To receive alert from Bishop Ikedi Blog, Adverts Placement, News, Articles & more, Contact via Whatsapp: 07032803990, email email@example.com