John King is seen at an awards ceremony at Patterson Elementary School in Washington. (Evelyn Hockstein/For The Washington Post)

The nation’s next education secretary is a man driven by what might have been had he not found refuge in public schools.

John B. King Jr.’s mother died of a heart attack when he was 8, and then his father descended into Alzheimer’s disease, leaving King an orphan at age 12. He moved around a lot, staying with relatives. School became the safest, most stable and most nurturing place he knew.

“New York City public school teachers are the reason that I am alive,” King said at the White House this month, after President Obama announced that he would succeed Education Secretary Arne Duncan at the end of this year. “Those teachers created amazing educational experiences, but also gave me hope — hope about what is possible, what could be possible for me in life.”

Quiet and mild-mannered, King is nevertheless one of the most polarizing figures in K-12 education. In choosing him, Obama — whose education policies have sparked backlash from a strange-bedfellows alliance of tea party conservatives and teachers unions — is choosing continuity.

As New York state schools chief from 2011 to 2014, King clashed with parents and teachers over his efforts to implement the same policies — including new teacher evaluations and new Common Core standards and tests — that the Obama administration has pushed hard nationwide.

John B. King Jr. thanks President Obama after being named secretary of education. He is taking over for Arne Duncan, who resigned on Oct. 2 (The White House/ Youtube)

Obama does not plan to formally nominate King as education secretary, avoiding a potential confirmation fight with the Senate’s GOP majority. Instead, King will serve as acting secretary for the final year of the president’s term.

A spokeswoman declined to make King available for an interview about his record and his plans for the department, but after an event at a D.C. school last week, he told reporters that his top priority is “moving forward with the ambitious agenda that Arne and the president have laid out,” from expanding preschool offerings to boosting the number of students who are getting into and through college.

King, 40, has built his career on the conviction that all children should have access to the kind of schools, and the kind of teachers, that he credits with saving his life.

One of them was Alan Osterweil at P.S. 276 in Brooklyn, who encouraged King to read the New York Times and Shakespeare in elementary school. “He was sort of a crazy guy — an ex-hippie who wore two-inch platform shoes,” King wrote in the Huffington Post in 2009. “But he was an amazing teacher.”

King was in Mr. Osterweil’s fourth-grade class when his mother, a Puerto Rico native and public school teacher, died of a heart attack. “The next morning, the only thing I insisted I wanted to do was go to school, your classroom,” King told Osterweil in an interview for the oral history project StoryCorps. “It felt like the most comfortable place to be.”

King fended for himself as his father, a lifelong educator who had been the first African American principal in Brooklyn, wrestled with an undiagnosed case of Alzheimer’s. After his father died, King bounced among relatives, then won a scholarship to the elite boarding school Phillips Academy Andover. He appreciated the academic challenge, he said after the D.C. school event last week, but chafed at the school’s rules and foreign culture. He was expelled after several years.

John King and Secretary of Education Arne Duncan attend an awards ceremony at Patterson Elementary School in Washington. (Evelyn Hockstein/For The Washington Post)

It was only after moving in with his aunt and his uncle, a retired Tuskegee Airman, that he began to find his way. He went to Harvard, where he co-founded a summer camp for at-risk children, and then — after earning a teaching degree at Columbia University — he taught social studies in Boston for three years.

In 1999, he co-founded one of Boston’s first charter schools. Roxbury Prep was one of a new class of “no-excuses” charters, with longer school days, strict discipline and a laser focus on raising test scores and getting students into college.

Students, who were overwhelmingly low-income and minority, succeeded in scoring high on state tests. But critics wondered at what price.

Pedro Noguera, an urban education expert who directs the Metropolitan Center at New York University, recalled a visit to Roxbury Prep. “I walked through that school and saw kids walking in silence, having lunch in silence,” Noguera said.

“I told John I’d never seen middle-class white children treated that way. And he said, ‘This is the model that works for our kids.’ ”

“I asked him, ‘Are you preparing these kids to be leaders, or followers? Because leaders get to walk and talk in the hallways.’ ”

Roxbury Prep, a middle school, eventually became part of Uncommon Schools, a network of what is now 44 schools serving 14,000 children in six cities.

Nearly all of Roxbury Prep’s alumni have gone on to graduate from high school, according to the school, and 60 percent are enrolled in or have completed college — far higher than average for low-income students.

In 2014, Roxbury Prep and all of Uncommon’s Boston middle schools scored higher than the city average on state tests. Fifty-two percent were proficient in math, for example, compared with 37 percent citywide.

When King went off to earn a law degree at Yale, he worked for Uncommon Schools, and later he continued there as a superintendent of its elementary and middle schools.

Brett Peiser, the chief executive of Uncommon Schools, said that parents choose the schools foremost because they are safe. They aim to produce a “structured yet joyful academic environment.”

“When we go into a classroom, the number one and number two things we look for are: Are the classes rigorous? Are they tackling material that’s going to push their thinking? But also, is there joy in the classroom?”

Peiser, who worked alongside King at Uncommon Schools, said King’s grounding in the classroom means that he understands what teachers and principals need to be successful. “This is a high school history teacher who’s now going to be the acting secretary of education,” Peiser said. “It is that perspective that he’s going to bring into his work.”

But teachers were among some of King’s most outspoken critics during his tenure as commissioner of New York education. He joined the department in 2009, helping to write its successful application for $700 million in federal Race to the Top funds. In return for the money, the state promised to adopt Common Core standards and tests, as well as new teacher evaluations tied to test scores.

The job of carrying out those promises largely fell to King when he became commissioner in 2011. Although more than 40 states adopted Common Core, in 2013 New York was among the first to begin giving aligned tests, and proficiency rates plummeted.

A growing chorus said that King’s changes were poorly executed and unfair, and were warping public education.

Teachers said they didn’t have the training or materials to teach what children needed to know. They also felt pressure to raise scores to protect their jobs, and parents said that their children were bearing the brunt of that pressure as schools devoted more time and resources to test prep.

At a raucous 2013 public meeting in Poughkeepsie, King faced an auditorium of irate parents and teachers shouting him down, drowning out his efforts to respond. One father questioned King’s decision to send his own children to a private Montessori school, where they were shielded from state tests. King canceled several additional public meetings meant to solicit feedback on the new standards, then rescheduled them.

He also refused to slow down, saying that the pace of change was warranted given the numbers of children who were graduating without the skills they needed, or were not graduating at all.

The strife fueled a movement of parents who refuse to let their children take state standardized tests; in spring 2015, 20 percent of New York students refused their tests.

“No one doubts his commitment to students, but he’s an idealogue who failed to listen and make course corrections even when everyone in the education community was sending the same message,” said Carl Kohn, a spokesman for the state teachers union, which voted no confidence in King in 2014.

But where critics see a zealot who refuses to listen, his supporters see a champion for children, a person willing to withstand a pummeling in the public square to do what he thinks is right.

“It’s not that he didn’t hear [critics]; it’s just that he didn’t agree,” said David M. Steiner, who preceded King as commissioner and now leads an education policy institute at Johns Hopkins University. “Not once did I sense that he took his eyes off what was best for students in his judgment.”

Steiner said the benefits of King’s changes will become clear in the long term. Like many Common Core backers, he thinks the new tests in New York and elsewhere are giving parents a more accurate sense of whether their children are being adequately prepared for college. King “was trying, often out of a sense of moral urgency, to tell the truth, and sometimes that was difficult for certain people to hear,” Steiner said.

King said recently that he did listen to feedback and made some adjustments in response, such as calling for a review of testing meant to help eliminate unnecessary exams. In retrospect, he said, he wished he had called for the review earlier.

King left his New York post in December to join Obama’s Education Department, where he has served as Duncan’s deputy. He lives in Takoma Park, Md., with his wife and two children, who attend public schools, according to his government biography.

Chancellor Merryl Tisch of the New York Board of Regents, who worked closely with King, said that in retrospect she wishes they had not rolled out new teacher evaluations and new standards at the same time. She also wishes they had done a better job communicating with parents before the changes started to unfold.

“The work that we did struck a nerve,” she said. “So maybe what we didn’t do was deliver enough anesthetic before we struck the nerve.”

Juliet Eilperin contributed to this report.