Preconnect is a link element, rel set to preconnect, naming an origin the page will soon need. The browser then does the groundwork in advance: it resolves the domain, opens the connection and performs the secure handshake. When the actual request comes, it can start sending immediately.
It helps when an important resource comes from a different domain and would otherwise wait for that setup, typical cases being a font host, an image CDN or a critical script. The saving is usually a few hundred milliseconds on the affected request, which is worth it only if that request is on the path to the first view.
The common mistake is overuse. Each connection held open costs the browser effort and can compete with more important work, and browsers may drop unused ones after a short time. A handful of preconnects for domains that are definitely needed early is plenty; for the rest, dns-prefetch is lighter. Example: a page that loads its main font from another domain adds a preconnect to it, with the crossorigin attribute that font requests require, so the font starts downloading sooner.
Related: dns-prefetch, prefetch, TLS handshake, render-blocking, network dependency tree