The First Actual Bug

On September 9, 1947, operators of the Harvard Mark II electromechanical computer traced a malfunction to a moth caught in one of the machine’s relays, where it physically blocked the contacts from closing. They removed the moth, taped it onto the page of their logbook, and wrote beside it: “First actual case of bug being found.” The logbook page, with the moth still attached, is preserved at the Smithsonian’s National Museum of American History.

It is a great story, but two things are often gotten wrong. First, the word “bug” for a fault did not start here. Engineers, including Thomas Edison, had used “bug” to mean a defect or glitch for decades before 1947, which is exactly why the logbook note calls it the “first actual case” of a literal bug, as a joke playing on the existing term.

Second, the entry is frequently credited to Grace Hopper personally. The Smithsonian record and other accounts indicate the log entry was not written by Hopper, and she may not have been the person who pulled the moth from the relay. Her real role came later: she enjoyed retelling the anecdote, which helped make the Mark II moth one of the most famous objects in computing history.

So the moth did not coin the word “bug,” and Hopper did not personally find it. What survives is a genuine artifact, a physical insect taped into a 1947 logbook, that perfectly captures an old piece of engineering slang the moment it met a real insect.

Sources

Last verified June 7, 2026