We survey the growing literature on group formation in the context of three types of social dilemma games: public goods games, common pool resources, and the prisoner's dilemma. The 62 surveyed papers study the effect of different sorting mechanisms-endogenous, endogenous with the option to play the game, and exogenous-on cooperation rates. Our survey shows that cooperators are highly sensitive to the presence of free-riders, independently of the sorting mechanism. We complement the survey with a meta-analysis showing no difference in terms of cooperation between studies implementing an endogenous and exogenous sorting. What is more, we find that it is no more likely for a cooperator to be matched with like-minded partners in endogenously formed groups than in exogenously formed groups. These observations are related. As we show in the survey, the success of a sorting method in matching like-minded individuals and the levels of cooperation are closely interlinked. * For valuable insights at various stages of this work, we wish to thank Rachel Croson, Fabrice Le Lec, Marie-Claire Villeval and the participants at the IMEBESS meeting in Barcelona, the ASFEE meeting in Rennes, and at the Cooperation: Interdisciplinary Methods Workshop in Lille. We are also grateful to the authors who responded to our various requests on the ESA forum.