# Disposable code

Disposable code is code cheap enough to produce that keeping it, maintaining it, or throwing it away are no longer decisions that carry much weight. The idea matters because it changes not how code gets written but *which projects get attempted at all*.

The traditional cost model for a piece of software has two parts: the effort to build it, and the open-ended tail of maintaining it. For any project the two together set a bar, and the project only happens if the expected value clears that bar. Small, marginal projects — a personal automation, a one-off script against an undocumented API — often failed the test not on the build cost but on the maintenance tail. Undocumented and unstable interfaces break; committing to chase those breaks forever is a real cost, and for a light switch it usually isn't worth it.

Coding agents move both terms. The build cost drops, and so does the cost of trying and failing — you can attempt something, watch it not work, and abandon it without having sunk much. That second part is what makes the marginal attempt rational: cheap failure, not just cheap success. And when the code was cheap the first time, regenerating it after it breaks — or deleting it and starting over — stops feeling like a loss. The instability of the underlying interface doesn't go away. It just stops being a reason not to begin. Simon Willison names this exactly in [[cheap-reverse-engineering]]: the maintenance burden of undocumented home-device APIs was doing more to suppress projects than the writing effort ever was, and dropping the cost of code removes that suppression.

The same shift appears across the wiki under other framings:

- [[port-not-patch-contribution]] — the open-source case. Once forking-and-porting a library is a 45-minute job, the incentive to send an upstream fix weakens; the cheap local rewrite wins.
- [[llm-as-average-democratizer]] and [[average-is-all-you-need]] — the market case. Cheap average output lifts the floor and flattens the value of being merely competent.
- [[language-choice-for-agents]] — the same cost function applied to language selection, where the human-throughput term that once favored Python inverts.

The counterweight is [[peril-of-laziness-lost]]. Disposability cuts both ways: code that nobody has to justify keeping is exactly the regime where bloat accumulates, because the friction that used to force simplicity — someone has to maintain this — is gone. Cheap-to-write and cheap-to-discard are the same property, and it removes the discipline along with the deterrent.
