Relativistic plasma jets are observed in many accreting black holes. According to theory, coiled magnetic fields close to the black hole accelerate and collimate the plasma, leading to a jet being launched 1-3 . Isolating emission from this acceleration and collimation zone is key to measuring its size and understanding jet formation physics. But this is challenging because emission from the jet base cannot be easily disentangled from other accreting components. Here, we show that rapid optical flux variations from a Galactic black--hole binary are delayed with respect to X--rays radiated from close to the black hole by ~0.1 seconds, and that this delayed signal appears together with a brightening radio jet. The origin of these sub--second optical variations has hitherto been controversial 4-8 . Not only does our work strongly support a jet origin for the optical variations, it also sets a characteristic elevation of ≲10 3 Schwarzschild radii for the main inner optical emission zone above the black hole 9 , constraining both internal shock 10 and magnetohydrodynamic 11 models. Similarities with blazars 12,13 suggest that jet structure and launching physics could potentially be unified under mass--invariant models. Two of the best--studied jetted black hole binaries show very similar optical lags 8,14,15 , so this size scale may be a defining feature of such systems. In June 2015, the Galactic X--ray binary V404 Cygni underwent the brightest outburst of an X-ray binary so far this century. We coordinated simultaneous optical observations from the William Herschel Telescope with X--ray observations from the NuSTAR space observatory on the morning of June 25. These were high frame--rate optical observations taken by the ULTRACAM instrument, sampling timescales down to 35.94 milliseconds (ms). Both optical and X--ray light curves show variability on a broad range of timescales characteristic of this source 15,16 (Fig. 1). The AMI telescope provided contiguous radio coverage throughout this period. Details of the observations may be found in Methods. These coordinated observations occurred on June 25, the day preceding the peak of the 2015 outburst. When the optical observations began, the X--ray intensity was two orders of magnitude below peak, and the spectrum was dominated by low--energy X--rays (i.e., it was in a state characterised as being relatively 'soft'). Steady, compact jet activity is not expected in such a state, and consistent with this, the radio spectral index is negative, as is typical of emission from discrete optically--thin ejecta. NuSTAR observations were interrupted about 2000 seconds later due to a period of Earth occultation, which separates the two halves (hereafter, 'epochs') of the sequence under consideration. At some point during this occultation, the source underwent a dramatic and very rapid change in its X--ray spectral state. When NuSTAR emerged from Earth occultation, the spectrum was instead found to have pivoted towards high energies, with a larger fraction of X--ray counts above 1...