Donald Trumpdescribed a Pentagon "plan of attack" and shared a classified map related to a military operation, according to an indictment.
The newly unsealed documents show the former president has been indicted on 37 felony counts related to retaining classified information, obstructing justice and false statements.
It marks the Justice Department's first official confirmation of a criminal case against Trump arising from the retention of hundreds of documents at his Florida home, Mar-a-Lago.
Also charged was Walt Nauta, a Trump aide who was seen on surveillance camera removing boxes at Mar-a-Lago.
The indictment accuses Trump of having improperly removed scores of boxes from the White House to take them to Mar-a-Lago, many of them containing classified information.
The indictment outlined two circumstances in which Trump allegedly showed the documents to others.
One occurred in a meeting with a writer at his Trump National Golf Club in Bedminster, New Jersey, where he described federal officials' "plan of attack" against him and purportedly acknowledging that he knew the information "is still a secret".
In a later meeting with a representative from his political action committee, Trump displayed "a classified map related to a military operation", acknowledging he "should not be showing it to the representative and that the representative should not get too close", prosecutors said.
In the next paragraph, prosecutors note how Trump, at a press conference while president in 2017, addressed media leaks and said that leaking classified information is "an illegal process" and people involved "should be ashamed of themselves".
The case carries grave legal consequences, including the possibility of prison if Trump is convicted.
But it also has enormous political implications, potentially upending a Republican presidential primary that Trump had been dominating and testing the willingness of party voters and leaders to stick with a now twice-indicted candidate who could face still more charges.
And it sets the stage for a sensational trial centred on claims that a man once entrusted to safeguard the nation's most closely guarded secrets wilfully and illegally hoarded sensitive national security information after leaving office.
The case adds to deepening legal jeopardy for Trump, who has already been indicted in New York and faces additional investigations in Washington and Atlanta that also could lead to criminal charges.
Legal experts - as well as Trump's own aides - had long seen the Mar-a-Lago probe as the most perilous threat and the one most ripe for prosecution.
Campaign aides had been bracing for the fallout since Trump's lawyers were notified that he was the target of the investigation, assuming it was not a matter of if charges would be brought, but when.
Don't miss the latest news from around Scotland an d beyond - sign up to our daily newsletter here.