How to Verify a WebFinger Profile URL Before Linking to a Fediverse Account

Learn how to inspect a WebFinger response, find a Fediverse profile page, review redirects, and independently confirm account ownership before linking.

Published
Reading time
6 min read
How to Verify a WebFinger Profile URL Before Linking to a Fediverse Account
On this page

Before linking to a Fediverse account, check that its WebFinger record identifies the account you intend to publish and points to the expected profile page. This tutorial shows how to inspect the record, handle redirects and missing records, and separate a successful lookup from proof of ownership.

Verification limitation: RFC 7033 and current platform documentation were not available to consult for this article, and the example request was not run. Before publishing, check the official documentation for the account’s platform and server version, especially its expected response and migration behavior.

Key Takeaways

  • A WebFinger request sends an account identifier as the resource query parameter to /.well-known/webfinger on the account’s domain.
  • The account identifier and the profile-page URL are different values. Inspect both before linking.
  • Treat redirects, missing records, and changed domains as reasons to investigate, not as automatic confirmation of a new profile.
  • A successful response does not establish that a person or organization owns an account. Confirm ownership through an independent channel.

Identify the account and make the request

Suppose a contact gives you the fictional Fediverse address @alice@community.example. Its account identifier for this example is acct:alice@community.example. The domain after the second @ determines where to start the lookup.

Example WebFinger request:

https://community.example/.well-known/webfinger?resource=acct%3Aalice%40community.example

The endpoint is /.well-known/webfinger; the encoded resource value represents acct:alice@community.example. The example domain is fictional. Replace it and the account name with the address you are authorized to check.

For a real address, a command-line request can make the encoding easier:

curl --show-error --include --max-time 15 --get \
  --data-urlencode 'resource=acct:alice@community.example' \
  'https://community.example/.well-known/webfinger'

This command displays response headers and the body. It does not automatically follow redirects. Check the HTTP status yourself: a completed curl command does not by itself mean the server returned a successful status. Keep normal TLS certificate verification enabled, and do not put credentials or private information in the query.

Advertisement

Look at the response body as JSON. A WebFinger response can contain a subject and a links array. For the fictional account, a plausible subject would be acct:alice@community.example. That is an identifier, not necessarily a URL you can open as a profile page.

To find a candidate page URL, inspect the entries in links for a rel value of http://webfinger.net/rel/profile-page. Its href may contain a web address such as https://community.example/@alice. That address is the profile-page URL to investigate; the example does not assert that this particular page exists.

Use this review before adding a link:

  1. Compare the subject with the identifier you requested. If it differs, investigate the discrepancy rather than assuming the two accounts are interchangeable.
  2. Find the profile-page link, if present, and inspect its complete href, including scheme and hostname. Do not substitute an unrelated link merely because it appears in the same response.
  3. Open the candidate page in a browser. Check that the displayed identity and account address match what your contact or organization supplied. Consider any page redirects separately.
  4. Confirm the account with an independent, trusted channel before publishing the link.

A record can contain other link relations, and not every response will provide the page link in the form you expect. Consult the server platform’s current documentation if the response is unclear. Do not assume that an API or protocol endpoint in the response is the public profile page.

Investigate redirects, missing records, and domain changes

Redirects

If the response has a redirect status, inspect its Location header before following it. Check whether the destination uses HTTPS and whether the host is expected. A redirect may be relative or absolute; resolve it against the request URL and check that the intended resource query is retained. Repeat the inspection for subsequent redirects, and stop if the chain is unexpected or excessive.

A redirect to another domain is a lead to investigate, not proof that the destination represents the same account. Likewise, inspect any redirect when opening the profile page. Avoid sending credentials or other sensitive data to an unfamiliar destination.

Missing or unavailable records

A missing record, an error response, malformed JSON, a certificate problem, or a timeout means you have not verified the link. Distinguish an account lookup failure from a temporary service or network failure; retry later if appropriate. Check the spelling of the account name and domain, then consult the platform’s documentation or ask the account administrator. Don’t guess the profile URL from the handle and publish it as verified.

Domain changes

When an organization changes domains or moves an account, check the old and proposed new addresses separately where possible. Compare their WebFinger responses and profile pages, and look for a migration notice or confirmation through an established organizational channel. An old domain may stop working or later be controlled by someone else, so an old link or redirect alone is not sufficient evidence of continuity.

Advertisement

Confirm ownership independently

WebFinger discovery tells you what a responding service says about an identifier. Even when the response and profile page agree, that does not prove that the account belongs to the person or organization named on the page. An attacker could control a domain or account that imitates a legitimate identity.

Use a channel you already trust: for example, ask an authorized contact through a verified organizational channel to confirm the exact account address and profile URL. Where practical, arrange a reciprocal link from an established official website or use an authenticated verification process controlled by your organization. Check the final URL again immediately before publication and periodically afterward, particularly after a reported move or domain change.

Common Mistakes

  • Linking the acct: identifier as if it were the profile page. Find and inspect the page URL separately.
  • Treating a successful HTTP response as ownership proof. It is one discovery signal, not an identity check.
  • Following cross-domain redirects without review. Inspect each destination and confirm unexpected changes independently.
  • Assuming a missing record proves an account is fraudulent. A configuration or temporary service problem may also prevent lookup.
  • Publishing a guessed URL. If the record or ownership cannot be confirmed, leave the link unpublished until you can verify it.

Best Practices

Record the account identifier, the profile URL you approved, the date checked, and the channel used to confirm ownership. Assign someone to review links when an account moves or a domain changes. For automated checks, apply appropriate network destination restrictions, redirect validation, timeouts, and response-size limits; parsing a URL alone is not a complete security control.

Conclusion

Use WebFinger to discover and inspect a candidate profile URL, then verify that URL and the account’s ownership through an independent channel. If the record, redirect chain, or identity is unclear, investigate before publishing.

What would your domain sell for?

A free TidyURLs account unlocks the Domain Estimator. It prices a name from 191,011 real domain sales.