For a club such as the European Union, an important question is whether a subset of the members should be allowed to form "inner clubs" and enhance cooperation. Flexible cooperation allows members to participate if and only if they benefit, but it leads to free-riding when externalities are positive. Flexible cooperation is better if the heterogeneity is large and the externality small, I show, but rigid cooperation is the political equilibrium too often. Both regimes are, however, extreme variants of a more general system combining mandatory and minimum participation rules. For each rule, I characterize the optimum and the equilibrium.