The Department of Temporal Investigations was a department within the Federation government, tasked with ensuring that time travel events which occurred under Federation jurisdiction were handled within guidelines established to prevent contamination of the timeline.
In 2373, two investigators from the Department, Dulmur and Lucsly, arrived on station Deep Space 9, to debrief Captain Benjamin Sisko on a recent time travel incident, wherein Klingon spy Arne Darvin utilized the Orb of Time to take the USS Defiant back to the year 2268 in an attempt to assassinate Captain Kirk. To prevent him from succeeding, Sisko and several members of his senior staff infiltrated both the USS Enterprise and Deep Space Station K-7, posing as crew members or visitors in order to thwart Darvin.
After the interview, Dulmur intimated to Sisko that he did not believe that the actions of his crew while in the past constituted a major violation of regulations regarding time travel. Lucsly, on the other hand, hedged, stating they'd have to review the incident first. (DS9: "Trials and Tribble-ations")
In 2380 when Doctor T'Ana informed Ensign Brad Boimler, suffering the effects of a faulty transporter, that she had contacted Division 14, he was initially freighted that she had meant "the time travel police." (LD: "Much Ado About Boimler")
Early drafts of the episode featured a Starfleet admiral: Ronald D. Moore commented: "There was going to be an admiral showing up on the station, and he wants to know what the hell happened. And when René and I started writing the teleplay, it was boring. It was the one boring element of an otherwise interesting script, and we wanted to have more fun. So we thought of a team of guys that came from the Department of Temporal Investigations. Given all the time travel that goes on in Star Trek, it seemed like that could be fun". (The Magic of Tribbles: The Making of Trials and Tribble-ations)
The names of the two DTI agents who interview Sisko about the incident with Darvin, Dulmur and Lucsly, are meant to be anagrams of Mulder and Scully from The X-Files, although "Dulmur" is spelled with two "U"s while "Mulder" is spelled with an "E". Their characterization was based on Friday and Gannon from Dragnet. (The Magic of Tribbles: The Making of Trials and Tribble-ations)
In 2011, Pocket Books began publishing Star Trek: Department of Temporal Investigations, a novel series in which Temporal Investigations takes a central role. The first novel was Watching the Clock, which ties up the loose ends of the Temporal Cold War and the second novel Forgotten History features the origins of the department in Kirk's era, analyzing the department's perspective on his time-travel escapades and how the Federation developed its understanding of how time travel could affect history, culminating in a meeting between Dulmer and Kirk due to a dimensional rift caused by an experiment in Kirk's era linking the two eras. The Collectors, an eBook, was released in December 2014, followed by Time Lock in September 2016. A third e-novella, Shield of the Gods, was released in June 2017.
In the novel A Pocket Full of Lies, it is revealed that, following the events of the Year of Hell, the Krenim of the new timeline have established a variation of the Department of Temporal Investigations known as the Krenim Temporal Defense Agency. However, in contrast to the DTI's goal to preserve the current history, the Agency's goal appears to be to use time travel to subtly ensure Krenim supremacy in the present timeline. As a result of this goal, they altered a timeline where their past enemies, the Rilnar and the Zahl, lived on a peaceful near-utopian planet, in favor of a timeline where the two were engaged in a protracted and pointless conflict on the same planet, because the peaceful timeline restricted Krenim expansion.