Proponents of digital currencies like bitcoins say these currencies provide greater security, lower costs and more stability than traditional forms of money like dollars and euros. But in the real world, bitcoins seem mostly to serve people engaged in illegal activities or speculation.

At a congressional hearing earlier this week, federal officials responsible for policing financial crimes said that bitcoins and other virtual currencies used in transactions primarily online could be subject to government regulation, an idea that might bring these units into the financial mainstream. After the hearing, the price of bitcoins shot up roughly 50 percent, to $900. But less than 24 hours later, it had tumbled to less than $700.

Bitcoins — software code generated by computers solving mathematical problems — are not tied to any national currency and are not backed by any government. But they have attracted a following among investors, technologists and criminals, who find them appealing because no centralized authority regulates them.

There are about 12 million bitcoins in existence now, and only 21 million units can ever be created. The limit is designed by the bitcoin creator or creators (known only by the name Satoshi Nakamoto) to ensure that there would never be a glut of coins that would depress their value.