TikTok#
Lets people sign in with their TikTok account, through Login Kit for the web. Last checked against TikTok's documentation on 31 October 2026.
Set it up#
Run
leptoskit auth provider add tiktok. It adds:[auth.providers.tiktok] client_id_env = "TIKTOK_CLIENT_ID" client_secret_env = "TIKTOK_CLIENT_SECRET"In TikTok for Developers, create an app and add Login Kit for the web, with the
user.info.basicscope.Add the Redirect URI
https://myapp.com/auth/callback/tiktok. TikTok only acceptshttpsaddresses, so try it during development through a tunnel to your machine, or on a deployed site.Set
TIKTOK_CLIENT_IDto the app's client key, andTIKTOK_CLIENT_SECRETto its client secret.Turn on the
auth-providersfeature, and runleptoskit auth doctor.
What sign-in gets#
The person's TikTok open_id, which is stable for your app, their display name, and their avatar.
TikTok shares no email address, so accounts made with TikTok start without one. Its web sign-in doesn't take PKCE: the code is bound to the browser that started the sign-in by its state and an HttpOnly cookie, and only your server can trade it, with the client secret.
Platforms#
It works on the web, and in iOS, macOS, and Android apps through the system browser, with the same redirect URIs: the browser comes back to your site, which sends it on to the app. See Sign-in for each platform.