The woman died early Tuesday and had been hospitalized since April 19, said Leonel Lopez, Cameron County epidemiologist.
Health officials stopped short of saying that swine flu caused the woman's death. State health department spokeswoman Carrie Williams said the woman had "chronic underlying health conditions" but wouldn't give any more details.
Lopez said the flu exacerbated the woman's condition. "The swine flu is very benign by itself," Lopez said. But "by the time she came to see us it was already too late."
The only other swine flu death in the U.S. was of a Mexico City boy who also had underlying health problems and had been visiting relatives in Brownsville, near Harlingen. He died last week at a Houston children's hospital.
There have been 26 other confirmed swine flu deaths, all in Mexico. Hundreds of cases of the disease have been confirmed in several countries, but mostly in Mexico and the U.S.
The teacher was from Harlingen, a city of about 63,000 near the U.S.-Mexico border. The school district where she worked announced it would close its schools for the rest of the week, though officials said anyone who might have contracted the disease from her would have shown symptoms by now.
The teacher was first seen by a physician April 14 and was hospitalized on the 19th. The woman delivered a healthy baby while hospitalized and stayed in the hospital until her death, said Lopez, who declined to give further details about the baby.
Doctors knew she had a flu when she came in, but did not know what kind, Lopez said. The area is undergoing a Type A influenza epidemic right now, of which the swine flu is one variety, he said. She was confirmed to have swine flu shortly before she died, he said.
Dr. Joseph McCormick, regional dean of the University of Texas School of Public Health's Brownsville campus, said the woman was extremely ill when she was hospitalized.
Mercedes Independent School District, where the woman taught, announced it would close its schools starting Wednesday and reopen May 11.
Based on the time the patient was admitted to the hospital and began to show symptoms of swine flu, anyone who had contracted the disease from her would have shown symptoms by now, McCormick said. Lopez also said students and employees of the school district where she worked shouldn't worry if they are currently healthy.
Meanwhile, U.S. health officials are no longer recommending that schools close because of the H1N1 virus.
The government last week advised schools to shut down for about two weeks if there were suspected cases of swine flu. Hundreds of schools around the country have followed that guidance and closed schools.
Health and Human Services Secretary Kathleen Sebelius said Tuesday that the swine flu virus had turned out to be milder than initially feared. She says the government is changing its advice on closing schools.
Sebelius says parents should still make sure to keep sick children at home.
The number of confirmed swine flu cases in the United States is now over 400, with hundreds more probably cases.
Also, The U.N.'s Food and Agriculture Organization has urged countries to step up. But in the United States, that task falls to the industry, not public health officials. Meat companies police their own farms to root out disease.
The effort to detect swine flu on U.S. farms gained urgency over the weekend as Canadian officials quarantined pigs infected with swine flu by a worker returning from Mexico. If the virus infects U.S. pigs, it could spread through herds kept in crowded barns and possibly threaten people.
Swine flu is a respiratory illness caused by a virus. The virus routinely causes outbreaks in pigs but doesn't usually kill many of them. Most recover.