On Thursday, The Washington Post gave Americans an easy way to tell when Secretary of the Interior Ryan Zinke is in Washington, D.C.: when he’s there, his flag is flown outside the headquarters. The flag, a “bison seal on a blue banner with seven white stars for the agency’s bureaus,” is brought down when he’s away. The trick works for Deputy Secretary David Bernhardt, too, as he has a separate flag of his own.
Zinke, a former Navy SEAL commander, is riffing on a tradition that has long been observed in the U.S. Navy. And that tradition has a good reason for existing: at sea, the custom is a way to point out which ship in a group the senior leader is on.
That method can also “ensure that proper ceremonial honors are rendered to dignitaries and officers,” according to Peter C. Luebke, a historian at the U.S. Navy. And, in keeping with that sea-faring tradition, there’s guidance for flying flags ashore as well. The mast a flag is hoisted on also indicates the stature of the visitor. For instance, Luebke adds, the President’s flag has historically flown at the mainmast while a different flag for the Vice President is flown at the slightly shorter foremast.
Get your history fix in one place: sign up for the weekly TIME History newsletter
But the U.S. didn’t invent this tradition. Like many American customs, it was originally borrowed from the nation’s erstwhile colonial overlords. The British Royal Navy has been doing something like this since at least the 17th century, “when the Duke of York flew the lord high admiral’s flag in his ship in 1665,” Luebke says.
The U.S. used the flag-raising tradition to indicate the rank of fleet commanders, squadron commanders and commodores, and added others during the Civil War. (The Army has a separate flag code.)
“The expansion of the Navy during the Civil War required reorganization of how the Navy worked,” he says. “New tasks meant new ranks needed to be added. So we had all of these ranks that we didn’t have before that deserved flags. Before the Civil War, the U.S. Navy had no admirals.”
One of the earliest examples of a federal agency head having a flag can been seen in this period, too. In 1866, a special insignia—a square blue flag with a white foul anchor in the center and four white stars at each corner—was designed to fly from the mainmast of a vessel whenever the Secretary of the Navy was aboard.