The first-ever recorded computer bug occurred in 1947, on a US Navy Mark II Aiken Relay Calculator at Harvard University. After a thorough check of the computer’s software and components, operators discovered a moth that had fried itself on the circuit board, interfering with signals.
The operators taped the said moth to a computer log, with the description “First actual case of bug being found”, and also added the comment that they had “debugged the computer”, coining both the terms “bug” and “debug” that are frequently used nowadays.
Although actual insects are a rare cause of problems in modern computers, the word “bug” is still the colloquial term for an error.