Since 2007, the number of refugees fleeing conflict and violence has doubled to about 25 million. Mass migration has destabilized the European Union, lead to broad changes in national immigration policies, and triggered the resurgence of far right, xenophobic political parties. Yet little is known about how illicit human smuggling institutions may be driving migration and the subsequent political changes. We leverage granular data on migrant flows across the Mediterranean, coupled with information about sea routes, riots at port cities, and wave conditions, to conduct two studies. We find substantial evidence that migrant flows respond to political and environmental risks as well as a government-led counter-smuggling intervention. These findings clarify drivers of migration and suggest actions that can be taken to mitigate human smuggling.