BEIJING — Missionaries. Corporate investigators. Billionaires. Legal activists.

China has a long history of arresting or holding foreigners for mysterious reasons, often in a tit-for-tat play to put pressure on overseas rivals. In recent years the number of such detentions has increased, a disturbing trend for foreigners visiting or conducting business in the country.

The Chinese government has detained two prominent foreigners in recent days: Michael Kovrig, a former Canadian diplomat, and Michael Spavor, a Canadian writer and entrepreneur. They are the latest foreigners to be held by the authorities, in what some experts said might be retribution for the arrest of a senior Chinese tech executive in Canada this month.

Here are some recent cases of foreigners caught in the cross hairs of China’s opaque legal system.

The Missionaries