Refactor

Verb · Noun · Slang & Abbreviations · Origin: 1999

Definitions

  1. Verb form of refactoring. 'Let me refactor this.' In practice, can mean anything from renaming a variable to rewriting an entire module while insisting 'it's just a small refactor.'

    In plain English: Cleaning up and reorganizing existing code to make it easier to understand and maintain, without changing what it actually does. Like rewriting a messy essay to be clearer.

Origin Story

Changing code's structure without changing what it does, named like math

**Refactoring** — restructuring existing code without altering its external behavior — was formalized as a discipline by **William Opdyke** in his 1992 PhD thesis at the University of Illinois. Opdyke defined specific, behavior-preserving transformations (rename variable, extract method, move class) that could be applied systematically.

The term borrows from mathematics, where **factoring** means breaking an expression into simpler components: just as you factor 12 into 2 × 2 × 3, you "refactor" code by breaking complex functions into smaller, clearer pieces. The "re-" prefix implies doing it again — restructuring code that was already factored but has grown tangled.

Martin Fowler's 1999 book *Refactoring: Improving the Design of Existing Code* brought the concept to mainstream developers and established a catalog of named refactoring techniques. IDEs like IntelliJ IDEA and Visual Studio incorporated automated refactoring tools, making operations like "rename everywhere" and "extract method" available with a keyboard shortcut. The practice is now so fundamental that "I'll refactor this later" has become both a promise and a running joke.

Coined by: William Opdyke (formalized); Martin Fowler (popularized)

Context: University of Illinois, 1992 PhD thesis; Fowler's book, 1999

Fun fact: The 'refactoring' entry in many spell checkers still shows a red squiggly line. Despite being a standard software engineering term for over 30 years, some dictionaries still haven't added it. Martin Fowler's book has sold hundreds of thousands of copies in a field where most technical books sell a few thousand.

Related Terms