This article analyzes endogenous efficiency gains from mergers. It considers oligopolistic homogeneous good markets and duopolistic and triopolistic markets under product differentiation (PD) (quantity and price competition). In a two-stage game, firms invest in costreducing innovation (with and without mergers) and then compete in output/prices. It is found that in homogeneous good markets, all possible mergers generate efficiency gains, and that these are most significant when R&D spillovers are very low or very high. Efficiency gains increase with the number of insiders and generally decrease with the number of outsiders. With PD, in most cases, the merger generates efficiency gains when spillovers and/or PD are sufficiently high. With PD, efficiency gains increase with spillovers, but may increase or decrease with the level of PD. The implications of the results for the relationship between competition and innovation outputs and for merger policy are discussed.