Manual:$wgImagePreconnect

Details
Adds  for the first valid foreign or local file repo, on pages containing images.

This is a hint to the browser that it should open a connection to the other host (e.g. upload.wikimedia.org), if it doesn't have one already. Doing so allows the connection setup to happen before page parsing is complete, and should result in faster image loading, especially on slow connections.

It may create unwanted traffic if there are many possible URLs from which images are served.