Hotelling's law
Hotelling's law is an observation in economics that in many markets it is rational for producers to make their products as similar as possible. This is also referred to as the principle of minimum differentiation as well as Hotelling's linear city model. The observation was made by Harold Hotelling (1895–1973) in the article "Stability in Competition" in Economic Journal in 1929. The opposing phenomenon is product differentiation, which is usually considered to be a business advantage if executed properly. Example

Suppose there are two competing shops located along the length of a street running north and south, with customers spread equally along the street. Both shop owners want their shops to be where they will get most market share of customers. If both shops sell the same range of goods at the same prices then the locations of the shops are themselves the 'products'. Each customer will always choose the nearer shop as it is disadvantageous to travel to the farther. One shop
For a single shop, the optimal location is anywhere along the length of the street. The shop owner is completely indifferent about the location of the shop since it will draw all customers to it, by default. However, from the point of view of a social welfare function that tries to minimize the distance that people need to travel, the optimal point is halfway along the length of the street. Two shops: halfway

Hotelling's law predicts that a street with two shops will also find both shops right next to each other at the same halfway point. Each shop will serve half the market; one will draw customers from the north, the other all customers from the south. Another example of the law in action is that of two takeaway food pushcarts, one at each end of a beach. If there is an equal distribution of rational consumers along the beach, each pushcart will get half the customers, divided by an invisible line equidistant from the carts. But, each pushcart owner will be tempted to push his cart slightly towards the other, moving the invisible line so that the owner is on the side with more than half the beach. Eventually, the pushcart operators will end up next to each other in the center of the beach. Social optimum 
It would be more socially beneficial if the shops separated themselves and moved to one quarter of the way along the street from each end — each would still draw half the customers but customers would, on average, make a shorter journey. However, neither shop would be willing to do this independently, as it would then allow the other to relocate and capture more than half the market. Deviating assumptions
When people along the street, or along the range of possible different product positions, consume more than a minimum number of goods (i.e. have discretionary income), companies can position their products to sections where consumers exist to maximize profit; this will often mean that companies will position themselves in different sections of the street, occupying niche markets. When prices are not fixed, companies can modify their prices to compete for customers; in those cases it is in the company's best interest to differentiate themselves as far away from each other as possible so they face less competition from each other. Political science
In a democracy, and especially in the American two-party system, political parties want to maximize the vote share allocated to their candidate. In theory, this means that political parties will adjust their platform to comply with the median voters' preferences. The Comparative Midpoints Model represents this idea best: Both political parties will get as close as possible to the competing party's platform while preserving its own identity. However, party primaries can complicate this dynamic and make the stable points harder to find. Application
The street is a metaphor for product differentiation; in the specific case of a street, the stores differentiate themselves from each other by location. The example can be generalized to all other types of horizontal product differentiation in almost any product characteristic, such as sweetness, colour, or size. The above case where the two stores are side by side would translate into products that are identical to each other. This phenomenon is present in many markets, particularly in those considered to be primarily commodities, and results in less variety for the consumer. An extension of the principle into other environments of rational choice such as election "markets" can explain the common complaint that, for instance, the presidential candidates of the two largest American political parties are "practically the same". The candidates elected during primaries are usually established figures within their own partisan camps. Electors in the middle of the political spectrum are more likely to be swing voters, and there is a tendency for the candidates to "rush for the middle" to appeal to this crucial bloc. The assumption is that people will choose the candidate with a closer ideology to their own, so that the most votes can be had by being directly in the center. In real life

This phenomenon can be observed in real life, not just in commodity businesses like bars, restaurants, and gas stations, but even in large, branded chains:

 McDonald's and Burger King
 McDonald's and Jollibee in the Philippines
 Alfamart and Indomaret in Indonesia
 Target and Walmart
 Lowe's and Home Depot
 CVS and Walgreens
 Whole Foods and Trader Joe's

See also 
 Location model
 Braess's paradox
 Nash equilibrium
Median voter theorem
 Commoditization
 Central place theory

References

Eponymous laws of economics
1929 in economics