SOLITARY confinement can be psychologically damaging for any inmate, but it is especially perverse when it is used to discipline children and teenagers. At juvenile detention centers and adult prisons and jails across the country, minors are locked in isolated cells for 22 hours or more a day. Solitary confinement is used to punish misbehavior, to protect vulnerable detainees or to isolate someone who may be violent or suicidal. But this practice does more harm than good. It should end.

A major study by the Department of Justice in 2003 showed that more than 15 percent of young people in juvenile facilities, some as young as 10, had been held in solitary. My own research, for Human Rights Watch and the American Civil Liberties Union, suggested that the practice of putting teenagers in solitary was more widespread in adult jails and prisons. A recent Justice Department investigation found that at any given time in 2013 as many as a quarter of adolescents held at New York City’s Rikers Island were in solitary confinement. Dozens had been sentenced to more than three months in solitary. Still others were held longer, for more than six months.

Only six states have laws on the books that prohibit certain forms of isolation in juvenile facilities. No state — nor the federal government — has banned the solitary confinement of teens in adult jails and prisons.

I have interviewed scores of young people about being in solitary. Their stories haunt me. I spoke with girls who told me that the experience brought back traumatic memories of rape and abuse. Other kids talked about losing control of themselves, of banging their heads against the walls of their cell. Many teens spoke in disturbing detail about suicidal thoughts and suicide attempts. One girl who spent four months in solitary confinement in a county jail at 16, ostensibly to be protected from adults there, told me that solitary was “a dark place.” Though there were lights in her cell, she said, “It is like being sunk in a hole.” A boy who had been alone for months in a county jail at 15 told me that isolation turned his thoughts to “the death-oriented side of life.”