Doped Mott insulators have a strong propensity to form patterns of holes and spins often referred to as stripes1, 2, 3, 4, 5. In copper oxides, doping also gives rise to the pseudogap state6, which can be transformed into a high-temperature superconducting state with sufficient doping or by reducing the temperature. A long-standing issue has been the interplay between the pseudogap, which is generic to all hole-doped copper oxide superconductors, and stripes, whose static form occurs in only one family of copper oxides over a narrow range of the phase diagram2, 7. Here we report observations of the spatial reorganization of electronic states with the onset of the pseudogap state in the high-temperature superconductor Bi2Sr2CaCu2O8+x, using spectroscopic mapping with a scanning tunnelling microscope. We find that the onset of the pseudogap phase coincides with the appearance of electronic patterns that have the predicted characteristics of fluctuating stripes8. As expected, the stripe patterns are strongest when the hole concentration in the CuO2 planes is close to 1/8 (per copper atom)2, 3, 4, 5, 8. Although they demonstrate that the fluctuating stripes emerge with the onset of the pseudogap state and occur over a large part of the phase diagram, our experiments indicate that the stripes are a consequence of pseudogap behaviour rather than its cause.