The unanimous ruling by three judges on the U.S. Court of Appeals for the District of Columbia Circuit rejected a request for the images by a conservative nonprofit watchdog group.
Judicial Watch sued for photographs and video from the May 2011 raid in which U.S. special forces killed bin Laden in Abbottabad, Pakistan, after more than a decade of searching.
The organization's lawsuit relied on the Freedom of Information Act, a 1966 law that guarantees public access to some government documents.
In an unsigned opinion, the appeals court accepted an assertion from President Barack Obama's administration that the images are so potent that releasing them could cause riots that would put Americans abroad at risk.
"It is undisputed that the government is withholding the images not to shield wrongdoing or avoid embarrassment, but rather to prevent the killing of Americans and violence against American interests," the opinion said.
The court ruled that the risk of violence justifies the decision to classify the images top secret, and that the CIA may withhold the images under an exception to the Freedom of Information Act for documents that are classified.
Judicial Watch did not immediately respond to a request for comment on the ruling. A spokeswoman for the Justice Department, which represents the Obama administration in court, had no immediate comment.
The images show a dead bin Laden at his compound in Pakistan, the transportation of his body to a U.S. ship and his burial at sea, the government has said.
Some of the photographs were taken so the CIA could conduct facial recognition analysis to confirm the body's identity, according to court papers.
The case is Judicial Watch Inc v. U.S. Department of Defense and CIA, U.S. Court of Appeals for the D.C. Circuit, No. 12-5137.