Dark ages was a term describing periods of history in which a civilization was perceived to have regressed culturally and scientifically. On Earth, "the Dark Ages" usually referred to parts of the Middle Ages in Europe.
Doctor Leonard McCoy denounced dialysis as something from the Dark Ages after being transported to San Francisco in 1986. (Star Trek IV: The Voyage Home). His counterpart in the alternate reality similarly described the medical instruments on the USS Franklin as being from the Dark Ages. (Star Trek Beyond)
After seeing the technological achievements of the Federation in 2368, Hannah Bates lamented that she and the others of the Genome colony had been living in the dark ages. (TNG: "The Masterpiece Society")