TIL during an interview about the casting of Jean-Luc Picard, Gene Roddenberry was asked by a reporter, "Surely they would have cured baldness by the 24th century?" Roddenberry answered, "In the 24th century, they wouldn't care."

I don't think that was the case of the military taking over government. In almost all the Star Trek series there's hints that there's a distinct civilian governing body that Starfleet answers to. In "The Final Frontier" movie when we see Colonel West's plan veto'd by the UFP president. And again in DS9's "Homefront" and "Paradise Lost," in which the UFP President is demonstrated to have clear authority over Starfleet. Furthering the point, that two parter was all about Starfleet officers plotting a coup d'tet against the civilian government. Which in turn could have lead to a civil war, given that many member worlds (and even a considerable percentage of starfleet itself) would not accept a starfleet formed government.

For external relations though, that's fairly understandable. Starfleet's mandate is exploration, so they're the ones that are out there exploring the galaxy and patrolling the space lanes. They're the ones in the field, that ones that have to deal with either first contact or whatever crisis may emerge. It's reasonable to assume that Starfleet officers are given authority to act on behalf of the Federation within certain limits.

However we've also seen that Starfleet certainly doesn't have full diplomatic authority. In TOS "A Taste of Armageddon," Ambassador Robert Fox was demonstrated to be able override Captain Kirk despite a civilian. Again this is shown in TNG's 'Sarek', in which Ambassador Sarek had overall command of the mission. It's probably safe to assume that Starfleet officers establish the groundwork, but once that's done the Federation will probably dispatch a dedicated team of diplomats to handle the hard work of relationship building.

/r/todayilearned Thread Parent Link - projects.latimes.com