Short answer
The Three Laws of Robotics are rules Isaac Asimov built into the fictional robots of his stories: do not harm humans, obey humans unless that causes harm, and protect yourself unless that breaks the first two rules. All three were first spelled out together in his short story "Runaround," published in the March 1942 issue of Astounding Science-Fiction.
Follow-up question Can the Three Laws of Robotics keep real AI safe?
The Three Laws of Robotics are probably the most famous rules ever written for machines, and they come from a short story. Isaac Asimov's "Runaround" appeared in Astounding Science-Fiction magazine, in its issue dated March 1942. In it, an engineer recites the rules that every robot's brain is built around. Asimov wrote the story in October 1941, and it was the first time all three rules appeared together in print.
In plain words, the laws say:
- Never hurt a human being, and never let one get hurt by doing nothing.
- Do what humans tell you, unless an order would break the first law.
- Keep yourself from damage, unless doing so would break the first or second law.
The order matters. Each law gives way to the ones above it, so a robot's priorities run from human safety, to obedience, to self-preservation.
Where the laws came from
Asimov had been writing robot stories since 1940. His robots were meant to avoid the kind of uprising shown in Karel Čapek's play R.U.R., where artificial workers wipe out their makers. Instead, they would be engineered products with safety built in.
According to The Encyclopedia of Science Fiction, Asimov credited John W. Campbell Jr., the editor of Astounding, with putting the three laws into words during a conversation in December 1940. Campbell, for his part, felt the laws were already implied in Asimov's earlier robot stories. The first law alone had appeared in Asimov's story "Liar!" in May 1941.
A detail for word lovers: in the magazine version of "Runaround," the engineer Gregory Powell calls them "the three fundamental Rules of Robotics." The familiar wording quoted today, with "Laws" in place of "Rules," is the one printed in book collections of the story, starting with I, Robot in 1950.
How "Runaround" tests the laws
The story is a puzzle, and the laws are the clue. Two engineers, Gregory Powell and Mike Donovan, are trying to restart an abandoned mining station on Mercury, the planet closest to the sun. Their equipment needs selenium, a chemical element, to keep running, and without it they will not survive the heat. They send their robot Speedy to fetch some from a nearby pool of selenium.
Speedy does not come back. He circles the pool, round and round, and when they reach him he talks nonsense as if drunk. Powell works out why:
| Pull on Speedy | Which law | How strong |
|---|---|---|
| Fetch the selenium | Second law (obey) | Weak: Donovan gave the order casually |
| Avoid a hidden danger near the pool | Third law (protect yourself) | Unusually strong: Speedy is so expensive that his self-protection was boosted |
Close to the pool, the danger outweighs the order, so Speedy backs off. Farther away, the order outweighs the danger, so he moves in again. At one distance the two pulls balance exactly, and he is trapped on that circle. New orders do not help.
Powell's solution is bold. He walks out into the deadly sunlight himself. Now a human is in danger, and the first law, stronger than the other two, snaps Speedy out of his loop to rescue him.
Try it: Invent your own robot dilemma. Pick a simple order, add a danger, and decide how strong each law should be. Then write two sentences explaining what your robot would do, and one sentence on how you would fix it if it gets stuck.
Why it mattered
"Runaround" turned robots from monsters into machines with rules, and the rules themselves into a source of drama. Many of Asimov's later stories, collected in I, Robot, turn on the same kind of problem: the laws sound clear, but words such as "harm" and "human" turn out to be slippery. Decades later he added a "Zeroth Law," putting the protection of humanity as a whole above the other three.
The story also reached people who would build real thinking machines. Marvin Minsky, one of the founders of artificial intelligence as a field, said that reading "Runaround" started him wondering how minds work, a question he kept pursuing for the rest of his career.
Can the Three Laws of Robotics keep real AI safe?
Not as written, and Asimov's own stories show why. The laws depend on a robot understanding ideas like "harm," "human" and "inaction," and on weighing them sensibly in situations nobody foresaw. Speedy follows the laws perfectly and still nearly gets his crew killed, because the weights were set badly and the order was vague.
Real AI systems in 2019 do not work from a short list of principles at all. A spam filter, a voice assistant or a self-driving car learns patterns from data and pursues goals its designers specify in code. The hard part is the same one Asimov dramatized: making sure the goals we give a system match what we actually mean, including in rare situations. Researchers call this the alignment or specification problem, and it is an active field of study.
So the laws are best read as a teaching story, not an engineering manual. They remind us that safety has to be designed in from the start, that priorities between goals must be explicit, and that clear-sounding rules can fail in practice. Many organizations writing AI ethics principles in 2019 are discovering exactly that: stating good values is the easy step, and turning them into behavior is the hard one.
Sources
- Runaround — Isaac Asimov, Astounding Science-Fiction, vol. 29, no. 1 (scan at the Internet Archive)
- Laws of Robotics — The Encyclopedia of Science Fiction (John Clute, David Langford)
- Runaround (story) — Wikipedia, September 22, 2019