Bitcoin (BTCUSD) has been in the headlines quite a bit lately, and it's not hard to see why. Not only is the digital currency up by about 1,500% in 2017 alone, but the wild swings and spikes have attracted lots of interest from investors. Looking past the headline numbers of how much bitcoin is worth now, here are six stats about bitcoin that tell you more of the story.

1. There will only be 21 million bitcoins created -- ever.

Bitcoins are created through a process known as "mining," where specialized computing hardware attempts to solve complex mathematical problems in exchange for newly created bitcoins. (Note: For all of the bitcoin enthusiasts out there, I understand that is a very simplified explanation of how mining works.)

Gold coins with bitcoin symbol.

Image source: Getty Images. (Note: This is an illustration -- there is no such thing as a physical bitcoin.)

The number of bitcoins that can be mined at a time is set to decline geometrically over time and will eventually reach zero -- more on that in a minute. The effect of this is a finite number of possible bitcoins that will ever be in circulation. That number will never exceed 21 million.

2. The last bitcoin won't be mined until 2140.

You read that right. There is an algorithm that controls how bitcoins are mined, and it slows down production over time.

Specifically, bitcoins are released in "blocks." Currently, 12.5 bitcoins are released with each block, and this number is cut in half every 210,000 blocks. In other words, the number of bitcoin released at a time will eventually drop to 6.25, then 3.125, and so on.

Without getting too technical, bitcoin mining is regulated so that roughly six blocks are created and released each hour, so it's mathematically possible to determine when the magic number of 21 million will be reached. The latest projections determine this date to be May 7, 2140. So, new bitcoins will continue to enter circulation for the next 123 years.

3. Millions of bitcoins may be lost forever.

According to a recent study by digital forensics firm Chainalysis, millions of bitcoins may have already been lost forever. The firm's estimates range from a low of 2.78 million to a high of 3.79 million.

There are various reasons why so many bitcoins could be out of circulation forever. One major source is coins that were mined in the early days, when bitcoins were worth just pennies (or less) and bitcoin holders weren't as diligent about keeping track of their encryption keys. There's one particularly sad example about someone who threw away a hard drive that contained the key to 7,500 bitcoins, which would be worth about $112 million today.

Even on the low end of the estimate, this translates to roughly 17% of the bitcoins that have been mined so far that are lost forever.

4. Somebody once paid 10,000 bitcoins for pizza. At least they got two.

The first real-world bitcoin transaction took place on May 22, 2010, in Jacksonville, Florida, when a man paid for two pizzas with 10,000 bitcoins. Based on the bitcoin price of $16,830 as I write this, this translates to a December 2017 equivalent of more than $84 million per pizza.

This sounds crazy now, but bitcoin didn't have much value until much later. Just two months prior, in March 2010, one early bitcoin user attempted to sell 10,000 bitcoins for $50 (total) and failed to find a buyer.

5. The first actual cash value of bitcoin was $0.003.

The first bitcoin exchange,, which no longer operates, launched. The first cash value for a bitcoin? $0.003. In other words, for $100, you could have bought 33,333 bitcoins.

Bitcoin has risen from $968 at the start of 2017 to $16,830 as I write this, a gain of about 1,640%. This sounds impressive, and it is, but consider that since it was first listed on that exchange, bitcoin has risen by 561,000,000%. To put this in perspective, Warren Buffett's company Berkshire Hathaway, which is widely regarded as perhaps the best long-term investing success story of all time, is up by about 2,400,000% in the 53 years since Buffett took the helm.

If you had purchased just $1,000 in bitcoin when it was first made available on an exchange, your initial investment would be worth $5.6 billion today. Of course, this assumes that you didn't sell your holdings when bitcoin jumped to a few dollars, which a lot of early adopters of the digital currency did.

6. To reach $1 million, bitcoin would have to become 16% of the world's money supply.

According to a recent estimate, the total amount of money in the world is estimated to be $83.6 trillion. This includes physical currency, as well as money on deposit in financial institutions. With approximately 13.7 million bitcoins in existence, this implies that bitcoin would need to achieve such widespread use that it makes up nearly one-fifth of the world's entire money supply.

This would be quite a stretch, but the point is that it's not impossible. While bitcoin still has a way to go before attaining anything that I'd call "mainstream" usage as a currency, the predictions from several experts that bitcoin will rise to $1 million aren't as crazy as they may seem.

To be clear, there are several obstacles and problems standing in the way of bitcoin achieving mainstream acceptance, and if these aren't overcome in a timely manner, it's also possible that speculators will start to head for the exits and send the price of bitcoin plunging. My point is simply that the potential is there for bitcoin to be worth much more than it is today.