X-ray flares have been discovered in black hole systems such as gamma-ray bursts, the tidal disruption event Swift J1644+57, the supermassive black hole Sagittarius A * at the center of our Galaxy, and some active galactic nuclei. Occurrences of X-ray flares are always accompanied by relativistic jets. However, it is still unknown whether or not there is a physical analogy among such X-ray flares produced in black hole systems spanning nine orders of magnitude in mass. Here, we report observed data of X-ray flares and show that they have three statistical properties similar to solar flares, including power-law distributions of their energies, durations, and waiting times, which can be explained by a fractal-diffusive, self-organized criticality model. These statistical similarities, together with the fact that solar flares are triggered by a magnetic reconnection process, suggest that all of the X-ray flares are consistent with magnetic reconnection events, implying that their concomitant relativistic jets may be magnetically dominated.