A soccer game is called a "derby" when the two teams in the game are both from the same town, city or region. A soccer game between two rival teams is also sometimes referred to as a "derby." A derby is the soccer equivalent of the sort of game that is called a "crosstown rivalry" in North American sports.
The derivation of the term "derby" is unclear. It is possible that its origins are in a particularly chaotic football game that was played in Derby for centuries. This annual game was played during Shrovetide, the three days before Ash Wednesday, with hundreds of players on each side.