This paper presents a theory of the internal organization of a decentralized firm that operates along more than one dimension; e.g., a multiproduct firm that operates along more than one dimension; e.g. a multiproduct firm that operates in more than one geography. Organization corresponds to the allocation of responsibility to general managers along each dimension and the incentives the general managers provide to the local managers of their product of their geography, respectively. A local manager thus can have incentives provided by two general managers, and hence the organization is matrix. The optimal matrix organization is characterized in terms of the demand and cost characteristics of the firm’s products and the nature of the competition it faces. In the absence of competition and with symmetric local markets, matrix organization is optimal when intraproduct spillovers (e.g., economies of scale) and intra-geography (e.g., products are substitutes) are conflicting, and when those spillovers are complementary, either a product or geography organization is optimal depending on which spillovers are greater. The effect of local competition is generally to reduce the set of demand and cost characteristics over which matrix organization is optimal. When matrix organization is optimal, it attains the profits of a centralized Stackelberg leader. With asymmetric local markets matrix organization can be optimal with complementary spillovers. Increased competition among identical multiproduct, multi-geography firms favors a product organization.