The price of bitcoin jumped above $8,000, extending a rally that has lifted the largest cryptocurrency by market value to its highest level in two months.

After a dismal first half of the year, bitcoin has shown signs of life in recent weeks. It hurdled back above $6,000 a token in late June, surpassed $7,000 last week and exceeded $8,000 on Tuesday. The 25% gain so far in July puts bitcoin on pace for its second biggest monthly gain this year.

Bitcoin...