The Story in Nine Chapters
Grace Hopper spent her childhood taking apart alarm clocks to see how they worked, then spent her career doing the same thing to bureaucracies, computers, and the assumption that machines could only ever speak in numbers. Rejected from the Navy for being too small, she talked her way in anyway and became one of the first three people in the United States to program a working computer. She built the first compiler when colleagues insisted a machine could never write its own code, helped create the programming language that still runs banks and governments today, and popularized -- without inventing -- the term 'debugging' after a moth turned up in a relay. Forced into retirement twice by Navy age limits, she was recalled twice, and left the service in 1986 as its oldest serving officer. The stories that grew up around her afterward -- the moth, the 'ask forgiveness' line, her rivalry with Ada Lovelace for the title of 'first programmer' -- are almost all slightly more complicated, and more interesting, than the legend.

Seven Alarm Clocks
Grace Brewster Murray was born December 9, 1906, in New York City, to an insurance broker father and a mother who loved mathematics and made sure her daughter got the same quality of education as her brother -- a deliberate choice in an era that rarely made it. At seven, Grace decided she needed to understand how an alarm clock worked and took one apart to find out. When that didn't fully satisfy her, she took apart six more before her mother realized what was happening to the house's clocks. She was rejected for early admission to Vassar College at sixteen -- her Latin scores weren't high enough -- and admitted the following year instead. She graduated Phi Beta Kappa in 1928 with a degree in mathematics and physics, already showing the trait that would define her entire career: an instinct to open up whatever system was in front of her, whether it was a clock or an institution, and find out exactly how it actually worked rather than accepting how it was supposed to work.

The Quiet Ending
Grace earned a master's degree from Yale in 1930 and married Vincent Foster Hopper, a Princeton graduate teaching English at NYU, that same June. In 1934 she completed a PhD in mathematics at Yale under Øystein Ore -- an unusual achievement for a woman in that era in any field, let alone mathematics -- while teaching at Vassar, where she was promoted to associate professor by 1941. The marriage quietly fell apart in the early 1940s; the couple separated and eventually divorced in 1945. It was childless, and she never remarried -- but she kept the Hopper surname for the rest of her life and career, the name under which virtually everything she would go on to accomplish became known. By the time the United States entered World War II, she was a tenured, respected professor at a good college, with a doctorate few women of her generation held. She was also, by her own account, restless -- and the war was about to hand her a use for that restlessness that Vassar's classrooms never could.

WAVES and the Mark I
Grace tried to enlist in the Navy in 1943 and was turned down twice over -- she was considered too small and underweight for the physical standards, and her mathematical expertise was judged more valuable kept in a civilian classroom than sent to war. She got a waiver anyway and joined the U.S. Naval Reserve's Women's Reserve, known as the WAVES. She graduated first in her class in 1944 and was commissioned a lieutenant, junior grade, assigned to the Bureau of Ships Computation Project -- housed, unexpectedly, at Harvard University, where a physicist named Howard Aiken had built the Harvard Mark I, the first large-scale electromechanical computer in the United States. Aiken, by most accounts, had not been eager to have a woman placed on his team. He made her his primary programmer within months anyway. Grace became one of the first three people in the country to program a working general-purpose computer -- a role that essentially did not exist as a job title before people like her invented what it meant.

The Moth in the Relay
Grace and the Mark I team spent the war on classified calculations that mattered immediately -- rocket trajectories, anti-aircraft gun range tables, minesweeper calibration -- and she personally wrote the 561-page operator's manual for the machine, the first serious documentation of what programming a computer actually involved. On September 9, 1947, working on the Mark I's successor, the Mark II, engineers on the team found an actual moth jammed inside one of the machine's relays, causing a malfunction. Someone -- probably not Grace herself -- taped the moth into the project logbook with the note 'first actual case of bug being found.' The word 'bug' for a technical malfunction already existed; Thomas Edison had used it in an 1878 letter, six decades earlier. What Grace actually did was tell the moth story, for decades afterward, in lecture after lecture, until it became inseparable from her name -- a case of someone becoming a myth's most famous narrator rather than its author.

A Machine That Writes Its Own Code
In 1949, Grace left Harvard for the Eckert-Mauchly Computer Corporation, joining the team building UNIVAC, one of the first commercial computers in America, and eventually becoming head programmer on the project. Her real breakthrough came in 1952: a program she called A-0, which she later named a compiler -- software that could translate symbolic instructions written by a human into the binary machine code a computer actually executed. The idea met real resistance. Colleagues, including some with far more formal credentials than hers in the young field, insisted that computers could only do arithmetic and that the notion of a machine translating and effectively writing its own programs was close to nonsensical. Grace kept building it anyway, and kept demonstrating that it worked, until the argument became moot. The compiler is now recognized as one of the foundational ideas of modern computing -- essentially every programming language written since relies on some descendant of the concept she had to argue people into taking seriously in 1952.

Teaching Computers English
Grace's next project pushed the compiler idea further: if a machine could translate symbolic math notation into machine code, why not plain English words? In 1956 her team built FLOW-MATIC, the first programming language built around English-like commands rather than mathematical symbols -- a design choice driven partly by her belief that business managers, not just mathematicians, needed to be able to read and eventually write programs themselves. In 1959 she joined the CODASYL consortium, a multi-organization committee working to build a standardized, machine-independent business programming language. The result was COBOL (COmmon Business-Oriented Language). Many people contributed to its formal specification, and Grace did not single-handedly write it -- but she is rightly remembered as the philosophy's driving advocate and the person who built and promoted the compiler technology that made an English-readable language practical to actually run. COBOL went on to become, for decades, the invisible backbone of banking, government, and insurance computing -- code still processing transactions today, more than sixty years after it shipped.

Amazing Grace
Navy age-limit rules forced Grace into retirement as a commander in 1966. Seven months later, she was recalled to active duty to help the Navy untangle its sprawling, inconsistent mess of incompatible computer languages -- a task suited exactly to the person who had spent the prior decade arguing that programming languages should be standardized and human-readable. Her subordinates nicknamed her 'Amazing Grace.' She became famous on the lecture circuit for a specific piece of showmanship: handing audiences an 11.8-inch length of wire, the maximum distance an electrical signal can travel in one nanosecond, so that engineers arguing about computer speed had something physical to hold instead of an abstract number. In her office she kept a wall clock that ran counterclockwise, explaining that 'humans are allergic to change... that's why I have a clock on my wall that runs counterclockwise' -- a tidy visual argument for the idea, expressed in various forms over many years, that the most dangerous phrase in an organization is some version of 'we've always done it this way.'

The Oldest Officer
Grace retired from the Navy for good in 1986, at age seventy-nine, holding the rank of rear admiral and, at the time, the distinction of being the oldest serving officer in the entire U.S. Navy. In 1991 she received the National Medal of Technology, one of the highest honors the United States gives for technical achievement, becoming the first woman to receive it individually. She kept speaking publicly well into her final years, still handing out nanosecond wires, still telling the moth story, still arguing for readable code and against institutional inertia to audiences that by then spanned three generations of engineers who'd grown up on tools built from ideas she'd fought to establish decades earlier. She died at her home in Arlington, Virginia, on New Year's Day, 1992, at eighty-five, and was buried in Arlington National Cemetery with full military honors -- a fitting resting place for someone whose entire adult working life had been spent inside the institution that twice tried to retire her and twice found it couldn't quite do without her.

The Myths That Outlived Her
In 1994, two years after her death, computer scientist Anita Borg co-founded the Grace Hopper Celebration of Women in Computing in her honor; it began with about five hundred attendees in Washington, D.C., and has since grown into the largest gathering of women and non-binary technologists in the world. In 1996 the Navy launched a guided-missile destroyer, USS Hopper, nicknamed 'Amazing Grace' after her -- one of a short list of American military vessels named for a woman. In 2016, President Obama posthumously awarded her the Presidential Medal of Freedom, the nation's highest civilian honor. Along the way, her legend picked up some rough edges that don't quite match the record: she is often credited with personally coining the words 'bug' and 'debug' rather than simply popularizing an incident and a term both older than she was, and she is sometimes framed as a rival or successor to Ada Lovelace's title of 'first programmer' -- a comparison that misses that Lovelace, a century earlier, never had a working machine to run her ideas on, while Hopper's claim rests on something more concrete: she was one of the first people anywhere to actually sit down and program a real, functioning computer, then spend the following four decades making that work possible for everyone who came after her.