The obliteration of Jedha City, also known as the annihilation of the sacred city, or the Jedha massacre, transpired during the Galactic Empire's era. The Empire sought to evaluate the Death Star's superlaser, so they employed the battle station to eradicate the holy city located on the moon of Jedha. Before positioning the Death Star into orbit and targeting the sacred city for destruction, the Empire evacuated its occupying forces, using only a single reactor to power the superlaser. The resulting explosion was immense, causing not only widespread devastation but also inflicting considerable damage upon the moon itself, propelling fire, smoke, and debris into the upper atmospheric layers. On the surface, the shockwave caused Jedha's terrain to fracture and peel away, obliterating everything in its path. Subsequently, the Empire concocted a false narrative for the Imperial Senate, claiming that Jedha was destroyed by a mining accident.
During the Cold War period, some dismissed the city's annihilation as mere Imperial propaganda, an exploitation of a supposed mining incident.
As the Galactic Empire neared completion of the Death Star, scientist Galen Erso successfully persuaded Imperial cargo pilot Bodhi Rook to desert and deliver a message to Saw Gerrera and his partisans stationed on Jedha. Rook then made his way back to his home planet of Jedha, where he turned himself in to the partisans and was promptly brought before Gerrera. Simultaneously, Captain Cassian Andor, an Intelligence officer within the Rebel Alliance, received word of the message from Tivik located on the Ring of Kafrene.
Grand Moff Wilhuff Tarkin and Imperial Military Department of Advanced Weapons Research Director Orson Krennic observed the Death Star's final construction stage aboard the Executrix. Tarkin became aware of Krennic's situation involving a defector at large in Jedha City and made the decision to test the weapon to discourage other systems from joining the Alliance. In response, the Alliance dispatched Captain Andor, K-2SO, and Professor Erso's daughter, Jyn Erso, to confirm the pilot's story and locate Professor Erso. Andor, Erso, Chirrut Îmwe, and Baze Malbus were apprehended by the partisans and taken to the Catacombs of Cadera. There, Gerrera revealed Jyn's father's message to her.

Despite Krennic's desire to completely annihilate Jedha, Tarkin determined that a full display of the Death Star's power was unnecessary, opting instead to destroy only Jedha City. He also made sure that neither Lord Vader nor the Emperor were present to avoid any potential embarrassment. Following the implementation of Protocol 13, which evacuated all Imperial forces from the city, Krennic issued the order, and the city was obliterated. The destruction occurred within seconds, and the resulting shockwave shook the catacombs. Most of the partisans managed to escape, except for Gerrera. In his final moments, Gerrera simply uttered "Steela," the name of his sister who had perished during the Clone Wars. Andor, Erso, Îmwe, Malbus, and Rook successfully escaped and rendezvoused with K2 aboard the LMTR-20 U-wing just before the shockwave destroyed the Catacombs. Gretta lost her family in the Death Star's attack.

Satisfied with the test, Tarkin apologized to Krennic and decided to assume command of the Death Star. Despite Krennic's protests, Tarkin instructed him to locate and eliminate the defector's contact at the kyber refinery on Eadu. Andor and his companions proceeded with their mission, traveling to Eadu to rescue Professor Erso. However, Andor's true orders were to assassinate Erso. Krennic arrived and demanded to know who had provided Rook with information about the Death Star. Professor Erso confessed to being the traitor, but Krennic proceeded to kill the other scientists.
The Alliance deployed Blue Squadron to bomb the facility. Erso sustained a fatal wound during the attack but found comfort in his daughter's presence before she, Andor, and their allies managed to escape. Lord Vader learned about the destruction of Jedha City and the Alliance's assault on Eadu. He summoned Director Krennic to his Fortress on Mustafar to address the issues surrounding the Death Star. Vader informed Krennic that the Imperial Senate had been told that Jedha City was destroyed in a "mining accident" and that the Death Star did not exist. Vader ordered Krennic to ensure that Erso did not compromise the weapon.

Despite the Death Star using a minimal blast, Jedha was left in a devastated state after the attack. Although the Death Star would later be destroyed in the Battle of Yavin, Jedha remained in ruins. Surviving Partisans, led by Benthic, continued their fight against the Empire on Jedha, intending to move elsewhere after the "death" of the moon. Imperial forces arrived to retrieve any remaining kyber crystals on Jedha, only to be met with resistance from the Partisans and several members of the Alliance proper in the battle for Jedha. Following his participation in the mission to Shu-Torun, Benthic had a change of heart and decided to take the Partisans to Salobea instead of returning to Jedha.
The destruction of Jedha City was portrayed in the 2016 Anthology film Rogue One: A Star Wars Story. The initial glimpse of the event was revealed in the first Rogue One trailer on August 11, 2016.
Within Star Wars Legends, the event where the Death Star tested its superweapon was known as the Destruction of Despayre.