We studied the optical counterpart of the intermediate-mass black hole candidate HLX-1 in ESO 243−49. We used a set of Very Large Telescope imaging observations from 2010 November, integrated by Swift X-ray data from the same epoch. We measured standard Vega brightnesses U= 23.89 ± 0.18 mag, B= 25.19 ± 0.30 mag, V= 24.79 ± 0.34 mag and R= 24.71 ± 0.40 mag. Therefore, the source was ≈1 mag fainter in each band than in a set of Hubble Space Telescope images taken a couple of months earlier, when the X-ray flux was a factor of 2 higher. We conclude that during the 2010 September observations, the optical counterpart was dominated by emission from an irradiated disc (which responds to the varying X-ray luminosity), rather than by a star cluster around the black hole (which would not change). We modelled the Comptonized, irradiated X-ray spectrum of the disc, and found that the optical luminosity and colours in the 2010 November data are still consistent with emission from the irradiated disc, with a characteristic outer radius rout≈ 2800rin∼ 1013 cm and a reprocessing fraction ≈2 × 10−3. The optical colours are also consistent with a stellar population with age ≲6 Myr (at solar metallicity) and mass ≈104 M⊙; this is only an upper limit to the mass, if there is also a significant contribution from an irradiated disc. We strongly rule out the presence of a young superstar cluster, which would be too bright. An old globular cluster might be associated with HLX-1, as long as its mass ≲2 × 106 M⊙ for an age of 10 Gyr, but it cannot significantly contribute to the observed very blue and variable optical/ultraviolet emission.