A v3 onion address is 56 characters of base32 followed by .onion. It looks random because it mostly is: it contains the service's Ed25519 public key, a two-byte checksum and a version byte (3). There's no registry and no DNS behind it. If you know the address, you know the key, and Tor can check that whoever answers actually holds the matching private key.
That self-authenticating property is the best thing about onion addresses and also the source of their biggest usability problem. Nobody can remember 56 random characters, so people copy them from directories, forums and search results, and scammers exploit that with lookalike addresses that share the first and last few characters. Check the whole thing, or better, get it from a source you already trust.
The older v2 addresses were 16 characters and based on RSA-1024. They were retired in 2021. If you see a 16-character address today, it's dead. Our onion directory lists v3 addresses only.