Google Search Console shows how your site appears in Google search. Before you can use it, Google asks you to prove that you own the domain. A Domain property covers every version of your site (with and without www, http and https) and is verified with a DNS record.
- In Google Search Console, add a Domain property and enter your domain without
https://orwww. - Copy the TXT record Google shows you. It starts with
google-site-verification=. - Sign in at your registrar (or wherever your domain's DNS is managed) and add a new TXT record with the name @ (some registrars leave the name blank) and the text you copied as its value.
- Save, then go back to Search Console and select Verify.
If verification fails at first, wait a while and try again: a new record can take a few hours to be seen, and up to 72 hours. Keep the record in place afterwards, because Google checks it again from time to time.
Adding a TXT record doesn't affect your website or email, and a domain can have several TXT records.
Another way
If you'd rather not touch DNS, add a URL prefix property instead and verify it from WordPress, for example with Google's Site Kit plugin or the verification option in your SEO plugin. A URL prefix property covers only the exact address you enter, such as https://www.example.com.