This is a demonstration of the Hugging Face OAuth flow in a static Space using only vanilla JS.
No external libraries are needed – just copy this HTML file in your Space!
Click "Sign in with HF" to start the authentication flow.
After authenticating, your access token and user info will be displayed below.
(Tokens are only stored locally in your browser and never sent anywhere else.)