Officials say students were watching a demonstration in chemistry class at W.T. Woodson High School in Fairfax County on Friday when the fire started. Five students and a teacher were injured. The cause of the fire is still under investigation. (WUSA9)

A chemistry demonstration at a Fairfax County high school went out of control Friday morning, with a flash of flame engulfing a group of students, leaving two with serious burns and also sending three others to the hospital.

The blaze at W.T. Woodson High School sent students scrambling as smoke and screams burst from a classroom and a teacher went running down the hall, her shirt still on fire. Helicopters and ambulances swooped onto the campus, and students spent much of the morning huddling together on the football field’s bleachers while ventilation fans cleared chemical-laden air from the school.

The incident began 10 minutes into second period, when a chemistry teacher poured flammable liquid onto a desk and lit it with a Bunsen burner, according to several students who said they were in the class. The teacher then introduced chemical elements, such as copper, to demonstrate their different effects on the colors of the flames — a well-known, captivating yet sometimes-risky experiment.

As the flame appeared to die down, the teacher poured more liquid onto the table, students said, causing a “splash of fire” to hit those nearby. One student said the teacher was not wearing any protective gear, nor were the students in the room, including those closest to the experiment.

One screamed when her hair caught fire. Another had burns to his face and singed eyelashes. Another student’s jacket caught fire.

“I was just lucky enough to take it off quickly,” said the student, whose left forearm was burned. He was taken to Inova Fairfax Hospital, where he was treated and released. To protect his privacy, his father allowed the student, a minor, to be quoted only if his name was not published.

Two other students also were taken to Inova Fairfax and later released. And two others, injured more seriously, were flown by helicopter to hospitals in the District.

By Friday afternoon, one of them was listed in critical condition and was in surgery at Children’s National Medical Center, according to Capt. Randy Bittinger, a fire department spokesman. That student’s condition later improved, and the student was moved to MedStar Washington Hospital Center, where doctors also were treating another student, who was in fair condition.

The classroom teacher suffered minor burns, according to fire officials.

A group of students in an adjacent class said that after they noticed smoke and screams coming from the classroom, they saw the chemistry teacher running down the hall with small flames on her shirt. They said a security guard stopped her and patted them out.

She was treated at the scene and has been speaking to investigators. Attempts to reach her on Friday were unsuccessful. A relative at her home said the teacher would not comment.

The fire disrupted the last day of the grading period in the county, as students headed into a festive four-day weekend that includes Halloween. Fire officials ruled Friday afternoon that the fire was accidental, the result of a classroom demonstration for students.

Fire Chief Richard Bowers confirmed that the class was watching a demonstration showing the changing colors of fire when the students were burned. He would not provide further details beyond saying that it was a “teacher-led instruction activity in the classroom” and that there was no explosion.

John Torre, a spokesman for the county school system, said the administration is conducting an internal review of what happened and how it happened.

Ken Roy, chief science safety compliance advisor for the National Science Teachers Association, said there is no way to know how many injuries are caused by science classroom accidents nationwide because no agency or organization tracks them. Also, there is no federal requirement that schools report such incidents.

But Roy said that in recent years, he has noticed an increase in the number of accidents reported to the association and in the news media.

Many of the accidents have involved the highly flammable liquid methanol, a form of alcohol, he said. In 2014, two students at a school in Manhattan were burned when a teacher conducted what is often called a “rainbow flame” experiment, using methanol to ignite different types of metal salts to create colored flames.

And at a Denver high school last year, a chemistry class demonstration using methanol burned five students, according to the U.S. Chemical Safety Board.

The board, an independent federal agency responsible for investigating chemical accidents, issued a safety alert last year warning teachers that they should use a vent hood — which funnels away potentially flammable fumes — when using methanol in classroom demonstrations or to not conduct the demonstrations at all because of an “unacceptable risk of flash fire.”

A fire department spokesman said he did not know whether methanol was being used in the activity that led to the fire at Woodson.

The fire is believed to have started in a classroom about 9:40 a.m. There were 31 students and two teachers in the classroom at the time, county school officials said.

Karen Garza, superintendent of Fairfax County Public Schools, said in a statement that she was “deeply saddened” by the incident.

“We are all deeply concerned about what happened today,” Garza said. “My thoughts and prayers go out to all of the victims and their families.”

Bowers, the fire chief, praised the school for its emergency procedures, saying that Woodson staff called 911 and evacuated students according to the school’s crisis plan, moving them in an orderly fashion to the football field.

“The school did exactly what they were supposed to do,” Bowers said.

The fire was still burning when firefighters arrived, he said, but it was extinguished before it spread to other parts of the school. About half of the classroom was damaged by fire, smoke and water, Bowers said.

Woodson student Alex Buchanan said that when the fire alarm went off, he at first thought that someone burned their lunch in a microwave. Then he saw the helicopters land on campus.

“People were running everywhere,” Buchanan said.

Megan McLaughlin, a School Board member who represents Woodson and whose son is a sophomore there, said she spoke Friday morning to the mother of a student who was in the classroom next door when the fire broke out.

“The students, hearing the screaming and the smoke, their minds went everywhere,” McLaughlin said. For students who have grown up hearing reports of school shootings and other violent incidents, “when something like this happens, they don’t know immediately why they’re having to evacuate the building, and I think it can be traumatizing.”

Students spent much of the morning on the school’s football bleachers. As they waited there, Principal Scott Poole told them that he had spoken to all of the injured students.

“I talked with all of them — they were awake, they were conscious,” Poole said, according to a recording of his remarks obtained by The Washington Post. “We’re all going to pray for them, for their recovery.”

Poole sent a message to parents Friday afternoon saying that the school planned to have Friday night’s football game go on as scheduled. School officials said that counselors would be available for students and asked the school community to keep the injured in their thoughts. The school is to reopen Wednesday, as scheduled.

Moriah Balingit, Dana Hedgpeth, Magda Jean-Louis, Justin Jouvenal and Patricia Sullivan contributed to this report.