I’m troubleshooting an Auth0 Native application using Authorization Code Flow with PKCE.
The application exists in my Auth0 dashboard, but authentication consistently fails with:
invalid_request: Unknown client
I’ve verified that the Client ID and tenant hostname in the failed Auth0 logs match the registered application exactly.
The failure reproduces in Chrome and Edge. The authorization request includes the expected callback URL, audience, and PKCE S256 parameters.
Can someone explain what could cause Auth0’s authorization endpoint to reject a Client ID that exists in the same tenant?
Is there a way to verify application registration consistency or determine whether this requires escalation to Auth0 Support?
Hi @ronnieshort454
Welcome to the Auth0 Community!
You are asking why Auth0’s authorization endpoint returns invalid_request: Unknown client for a Native application using Authorization Code Flow with PKCE, when the Client ID exists in the same tenant.
[Common Root Causes]
-
Non-printable Characters or Encoding Issues in client_id
-
Auth0 matches client_id using exact byte-for-byte string equality in MongoDB/Redis.
-
If the configuration was copied with trailing or leading whitespace, a newline (\n), a carriage return, or a zero-width space, the query string may transmit an unencoded or encoded character (%20, %0A) that prevents the database lookup from finding a match.
-
Custom Domain vs. Canonical Domain Routing Mismatch
-
If your application routes requests through a Custom Domain (e.g., auth.yourdomain.com), the edge proxy or CDN maps incoming requests to a specific tenant container.
-
If a custom domain configuration is pointed to or shared across multiple environments (e.g., Staging vs. Dev), or if the CNAME/CDN routing is stale, the request may hit a different tenant container where that client_id does not exist
-
Dynamic Client Registration / CIMD Identifier Mismatch
- If the application was registered using Dynamic Client Registration (DCR) or Client Identifier Metadata Documents (CIMD), Auth0 expects the metadata document URL as the
client_id on the /authorize endpoint, rather than Auth0’s internal pointer ID (e.g., tpc_...). Supplying the internal pointer ID produces invalid_request: Unknown client.
-
Internal Caching or Database Replication Lag in auth0-server
-
The Auth0 Management API (api2) and runtime authentication pipeline (auth0-server) read from primary/replica database nodes and local caches.
-
A replication delay across database nodes, an internal shard partition, or an invalid/corrupted cache entry can cause api2 (the Dashboard) to show the client while auth0-server fails to resolve it at runtime.
[Solution]
Verify whether the client actually exists in the tenant’s data layer:
A. Query the Auth0 Management API directly
Run a direct GET against the Management API using a Management API Access Token:
curl --request GET \
--url "https://{YOUR_TENANT}.{REGION}.auth0.com/api/v2/clients/{CLIENT_ID}" \
--header "Authorization: Bearer <MANAGEMENT_API_TOKEN>"
-
If it returns 404 Not Found:
The client does not exist in the tenant datastore. The dashboard view is either stale, looking at a cached browser state, or open on a different tenant/region.
-
If it returns 200 OK:
The client exists in the datastore. Inspect the response payload:
-
Check the exact string length of client_id (confirm there are no extra spaces or formatting characters).
-
Verify app_type is set to "native".
-
Verify grant_types contains "authorization_code".
-
Confirm the expected callbacks include your redirect URI.
B. Test with a Minimal Direct /authorize Request
Bypass the native SDK, browser storage, and custom domain by issuing a direct GET in an incognito window against the canonical domain ({tenant}.{region}.auth0.com):
https://{YOUR_TENANT}.{REGION}.auth0.com/authorize?
response_type=code&
client_id={CLIENT_ID}&
redirect_uri={CALLBACK_URL}&
scope=openid%20profile%20email&
code_challenge={CODE_CHALLENGE}&
code_challenge_method=S256
-
If it works on the canonical domain but fails on the custom domain, the issue is in the custom domain CDN/proxy configuration.
-
If it still returns Unknown client with the exact string from the Management API, the issue is internal replication/caching within Auth0.
Kind Regards,
Nik