Scaffolding

In software development, scaffolding refers to temporary code and data built to support development, debugging, and testing, but not intended to be part of the finished product.

The metaphor is drawn from construction, where scaffolding provides the temporary structure that enables workers to build a permanent one. Software scaffolding serves the same role. Stubs, mock data, test harnesses, and throwaway driver programs that allow components to be developed and exercised in isolation before the surrounding system exists. Once the real components are in place, the scaffolding is removed.

The term is also widely used to describe code generation – the automated production of boilerplate project structure, files, and configuration from a template or command-line tool. Many frameworks provide scaffolding commands that generate a working skeleton for a new feature or resource. Ruby on Rails popularized this approach, generating models, views, controllers, and database migrations from a single command. Similar tooling is now common across the ecosystem, from Angular’s ng generate to create-react-app and beyond.

In this sense scaffolding is not throwaway code but a productivity mechanism for accelerating the start of new work by eliminating repetitive manual setup.