SAN FRANCISCO — The currency they were after was virtual, but the guns they carried were anything but.

In the beach resort of Phuket, Thailand, last month, the assailants pushed their victim, a young Russian man, into his apartment and kept him there, blindfolded, until he logged onto his computer and transferred about $100,000 worth of Bitcoin to an online wallet they controlled.

A few weeks before that, the head of a Bitcoin exchange in Ukraine was taken hostage and only released after the company paid a ransom of $1 million in Bitcoin.

In New York City, a man was held captive by a friend until he transferred over $1.8 million worth of Ether, a virtual currency second in value only to Bitcoin.