The black hole X-ray transient GX 339−4 was observed with the Swift satellite across the hard-to-soft state transition during its 2010 outburst. The ultraviolet (UV) flux measured with the filter UVW2 of the Swift/UVOT started to decrease nearly 10 days before the drop in the hard X-ray flux when the hard-to-soft state transition started. The UV flux, FUV, correlated with the X-ray flux, FX, as before the drop in the UV flux. During the UV drop lasting about 16 days, the X-ray flux in 0.4–10 keV was increasing. The drop in the UV flux indicates that the jet started to quench 10 days before the hard-to-soft state transition seen in X-rays, which is unexpected.