Skip to content
Benjamin Wootton.Better Software
Software

Internal Versus External Code Quality

2 April 2012

By Benjamin Wootton

2 min read

There are two kinds of code quality, and they are judged by two different audiences.

External quality is what a user experiences. Does the feature work? Is the screen clear? Does the system stay up under load? Does it respond quickly? These are the qualities that decide whether the product is useful and whether anyone keeps using it.

Internal quality is what a developer experiences when they open the code. Is the structure clear? Are the names honest? Can a change be made in one place, or does it leak across five? Is there a test that tells you quickly when you have broken something? These qualities decide whether the software can keep changing after the first release.

Both matter, but they fail in different ways. Poor external quality is visible immediately. Users complain, support tickets arrive and the product loses trust. Poor internal quality is quieter. It shows up as estimates that keep growing, small changes that take days, and a team that becomes afraid to touch the parts of the system that matter most.

The trap is to treat one as a substitute for the other. A beautifully structured codebase that does not solve the user's problem is an expensive hobby. A feature that works today but cannot be changed safely tomorrow is a debt that someone else will pay.

I like to think about the two together. External quality sets the direction: the software has to do something valuable for a real person. Internal quality keeps the direction affordable: the team has to be able to continue delivering value without the cost of each change rising forever.

In practice, that means writing tests at the level where they give confidence, keeping the design as simple as the problem allows, and paying attention to the parts of the code that change most often. It also means listening to users and to the people who maintain the system. Neither group has the full picture on their own.

The best teams I have worked with held both ideas at once. They cared about the experience of the person using the software, and they cared about the experience of the person changing it. That combination is what makes quality sustainable.

For the testing side of this, read why developer testing matters. For the process side, what agile software development means explains how I think about goals versus techniques. The idea of technical debt is covered well by Martin Fowler.

Reference shelf

Sources and further reading for this note.