Background Sex workers’ risk of violence and ill-health is shaped by their work environments, community and structural factors, including criminalisation. Aim We evaluated the impact of removing police enforcement on sex workers’ safety, health and access to services. Design Mixed-methods participatory study comprising qualitative research, a prospective cohort study, mathematical modelling and routine data collation. Setting Three boroughs in London, UK. Participants People aged ≥ 18 years, who provided in-person sexual services. Interventions Simulated removal of police enforcement. Outcomes Primary – recent or past experience of sexual, physical or emotional violence. Secondary – depression/anxiety symptoms, physical health, chlamydia/gonorrhoea, and service access. Results A combination of enforcement by police, local authorities and immigration, being denied justice when reporting violence, and linked cuts to specialist health and support services created harmful conditions for sex workers. This disproportionately affected cisgender and transgender women who work on the streets, use drugs, are migrants and/or women of colour. Among women (n = 197), street-based sex workers experienced higher levels than indoor sex workers of recent violence from clients (73% vs. 36%), police (42% vs. 7%) and others (67% vs. 17%); homelessness (65% vs. 7%); anxiety and depression (71% vs 35%); physical ill-health (57% vs 31%); and recent law enforcement (87% vs. 9%). For street-based sex workers, recent arrest was associated with violence from others (adjusted odds ratio (AOR)) 2.77, 95% confidence interval (CI) 1.11 to 6.94). Displacement by police was associated with client violence (AOR 4.35; 95% CI 1.36 to 13.90) as were financial difficulties (AOR 4.66; CI 1.64 to 13.24). Among indoor sex workers, unstable residency (AOR 3.19; 95% CI 1.36 to 7.49) and financial difficulties (AOR 3.66; 95% CI 1.64 to 8.18) contributed to risk of client violence. Among all genders (n = 288), ethnically and racially minoritised sex workers (26.4%) reported more police encounters than white sex workers, partly linked to increased representation in street settings (51.4% vs. 30.7%; p = 0.002) but associations remained after adjusting for work setting. Simulated removal of police displacement and homelessness was associated with a 71% reduction in violence (95% credible interval 55% to 83%). Participants called for a redirection of funds from enforcement towards respectful, peer-led services. Limitations Restriction to one urban locality prevents generalisability of findings. More interviews with under-represented participants (e.g. trans/non-binary sex workers) may have yielded further insights into inequities. Correlation between different risk factors restricted outcomes of interest for the modelling analyses, which were largely limited to experience of violence. Conclusion Our research adds to international evidence on the harms of criminalisation and enforcement, particularly for women who work on street and/or are racially or ethnically minoritised. Findings add weight to calls to decriminalise sex work, tackle institutionally racist, misogynist and otherwise discriminatory practices against sex workers in police and other agencies, and to (re)commission experience-based, peer-led services by and for sex workers particularly benefiting the most marginalised communities. Future work Realist informed trials, co-produced with sex workers, would provide rigorous evidence on effective approaches to protect sex workers’ health, safety and rights. Funding This synopsis presents independent research funded by the National Institute for Health and Care Research (NIHR) Public Health Research programme as award number 15/55/58.