# Design Pattern

> A known way to solve a problem that keeps coming up in code.

**Field:** Software Development  
**Category:** Architecture  
**Also known as:** Design Patterns, Software Design Pattern, Gang of Four Patterns

## Think of it like

Think of it like a recipe card. Many cooks have made the dish, so you follow the tried way.

## Definition

A design pattern is a known answer to a problem that comes up again and again in code. It is not code you copy, but a shape you follow and fit to your case. Each pattern has a name, so a team can say observer instead of explaining the idea each time. The 1994 book by the Gang of Four listed 23 of them. Many are now built into languages and frameworks.

## Example

Lucy needs many parts of her app to update when a setting changes. A teammate says use the observer pattern, and she knows the shape at once.

## Why it matters

Patterns give teams shared words for designs. They also save you from solving a solved problem badly.

## Common mistake

Forcing patterns into code that does not need them. Use one when the problem it solves is really there.

## Three principles

- **A known answer.** To a common problem.
- **A shape, not code.** Fit it to your case.
- **Shared names.** Faster team talk.

## Related terms

- [Singleton Pattern](https://learn.benibix.com/term/development/singleton-pattern)
- [Observer Pattern](https://learn.benibix.com/term/development/observer-pattern)
- [Factory Pattern](https://learn.benibix.com/term/development/factory-pattern)
- [Object-Oriented Programming (OOP)](https://learn.benibix.com/term/development/object-oriented-programming)
- [Decorator Pattern](https://learn.benibix.com/term/development/decorator-pattern)
- [Builder Pattern](https://learn.benibix.com/term/development/builder-pattern)
- [Facade Pattern](https://learn.benibix.com/term/development/facade-pattern)

---

Source: https://learn.benibix.com/term/development/design-pattern
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
