According to Texas Governor Greg Abbott, the gunman Salvador Ramos, 18, lived in the area. He was shot dead by police.
Mr Abbott said Ramos abandoned his vehicle and went into the school at 11.30am local time armed with a pistol and a rifle.
“He shot and killed horrifically, incomprehensibly, 14 students and killed a teacher,” he revealed before the death toll rose.
Ramos is also suspected of killing his grandmother at the beginning of the rampage.
The mass shooting took place at Robb Elementary School in the town of Uvalde, about 83 miles from San Antonio, America’s seventh largest city.
It is the deadliest at a US grade school since the shocking attack in Sandy Hook, Connecticut, almost a decade ago.
Local police chief Pete Arredondo said Robb Elementary School is attended by children in second, third and fourth grades, meaning its pupils range between 7 and 10.
Governor Abbott said two officers were also hit during the exchange of gunfire with the shooter but were not seriously injured.
CBS News added Ramos’s second weapon was AR-15 semiautomatic rifle.
He also had high-capacity ammunition magazines when he entered the school, according to sources.
It was not immediately clear how many people, in addition to the dead, were injured. Officials have not revealed a motive.
Earlier, Uvalde Memorial Hospital said 13 children were taken there. Another hospital reported a 66-year-old woman was in critical condition.
A 10-year-old girl is fighting for life at San Antonio’s University Hospital.
Robb Elementary School has an enrollment of just under 600 students.
Tuesday’s shooting is one of the deadliest in Texas history and occurred four years after a gunman fatally shot 10 people at Santa Fe High School in the Houston area.
In 2017, a gunman at a Texas church killed more than two dozen people during a Sunday service in the small town of Sutherland Springs. In 2019, another shooter at a Walmart in El Paso gunned down 23 people in a racist attack.
A heavy police presence surrounded Robb Elementary School within minutes as officers in heavy vests diverted traffic and FBI agents came and went from the building.
White House press secretary Karine Jean-Pierre said President Joe Biden has been briefed on the school shooting on Air Force One as he returns from a five-day trip to Asia and would continue to receive updates.
Jean-Pierre said Biden will deliver remarks later in Washington, adding: “His prayers are with the families impacted by this awful event.”
Biden has ordered the US flag to be flown at half-mast until Saturday at all public buildings, military posts and naval stations, vessels, embassies and consular offices in the US and abroad.
The shooting in Texas came less than two weeks after a gunman opened fire at a supermarket in Buffalo, New York, killing 10 black shoppers and workers in what officials have described as a hate crime.
Uvalde is home to about 16,000 people and is the seat of government for Uvalde County.
The town is about 75 miles from the border with Mexico. Robb Elementary is in a mostly residential neighborhood of modest homes. There is a funeral home across the street from the school.
Many children have been taken to the nearby Willie DeLeon Civic Centre to be reunited with their families.
The shooting came days before the National Rifle Association annual convention was set to begin in Houston.
Governor Abbott and both of Texas’ US senators were among elected Republican officials who were scheduled speakers at Friday’s leadership forum sponsored by the NRA’s lobbying arm.