Skip to content
ecdsa.com

WKD (Web Key Directory)

A way to publish OpenPGP keys on your own domain under /.well-known/openpgpkey/, so mail clients can fetch the key for an e-mail address over HTTPS (draft-koch-openpgp-webkey-service).
Also written asWeb Key DirectoryWKDopenpgpkeyWeb Key Service

The local part of the address is lowercased, hashed with SHA-1 and encoded in z-base-32, giving a 32-character name. In the advanced method the key is fetched from https://openpgpkey.example.org/.well-known/openpgpkey/example.org/hu/ followed by the hash and ?l= plus the local part; the direct method uses https://example.org/.well-known/openpgpkey/hu/ followed by the hash. The file is the binary key, and a policy file in the same directory signals that the domain supports WKD.

WKD ties key discovery to control of the domain and its WebPKI certificate rather than to a keyserver, and GnuPG (gpg --locate-keys), Thunderbird, Proton Mail, Mailvelope and others query it. gpg --with-wkd-hash -k user@example.org prints the hashed name to publish.

Standards and references

All terms