SocialToAIStart freeConsole

What is a Douyin sec_uid, and how do I get it?

A Douyin sec_uid is the long code starting `MS4wLjABAAAA` that identifies an account, in a profile's web link after `/user/`. To get it, copy it from that link, or give the profile call any profile link or share text, 2 credits, and read `id` in the answer. It is not the short Douyin number on a profile, and not a Xingtu creator ID.

Where to get it

You haveWhat it looks likeHow to get it
A profile's web linkhttps://www.douyin.com/user/MS4wLjABAAAAZ0aPDJzFhBrs0q3wVsp2a9WWrBuAUMsVyygoaO0bCw8Copy what follows /user/, up to any ?
A share link from the apphttps://v.douyin.com/…Give it to the call below; the answer's id is the sec_uid
Only a nameSearch first with search and take the account from a result, or search Xingtu if you need its data

Not to be confused with

IDWhat it isTakes it
sec_uidThe long code starting MS4w. Every Douyin account has oneAccount profile, account posts
Douyin numberThe handle shown on a profile, which its owner can changeNot taken as an ID here; search for it
Xingtu creator IDA string of digits on Xingtu, the platform's creator marketplaceThe Xingtu interfaces

One real request

cURL
curl https://api.socialtoai.com/v1/user_profile \  -H "Authorization: Bearer $SOCIALTOAI_API_KEY" \  -H "Idempotency-Key: $(uuidgen)" \  -H "Content-Type: application/json" \  -d '{    "platform": "douyin",    "id": "MS4wLjABAAAAZ0aPDJzFhBrs0q3wVsp2a9WWrBuAUMsVyygoaO0bCw8"  }'
A recorded answer (names and text removed)
{  "request_id": "req_00000000-0000-4000-8000-000000000001",  "schema_version": "v1",  "fetched_at": "2026-10-12T19:01:22.000Z",  "action": "user_profile",  "platform": "douyin",  "status": "ok",  "items": [    {      "platform": "douyin",      "id": "…",      "ref": "…",      "approx": [],      "type": "account",      "username": "…",      "name": "…",      "url": "https://example.com/…",      "bio": "…",      "verified": true,      "followers": 4022,      "following": 115,      "posts_count": 1094    }  ],  "unavailable": [],  "warnings": [],  "applied_params": {    "id": "MS4wLjABAAAAZ0aPDJzFhBrs0q3wVsp2a9WWrBuAUMsVyygoaO0bCw8"  },  "cost_credits": 2,  "billing": {    "cost_credits": 2,    "balance_credits": 98,    "today_spend_credits": 2,    "daily_limit_credits": null,    "daily_remaining_credits": null,    "display": "This call: 2 credits (≈ $0.0067). Balance: 98 credits (≈ $0.33)."  },  "replayed": false}

FAQ

Why do all sec_uids start the same?

MS4wLjABAAAA is a fixed prefix of the format; what tells accounts apart comes after it. This is what we see in the IDs, not something Douyin documents.

Does it change?

It stays with the account as far as we have seen, unlike the Douyin number, which its owner can change. Keep it rather than the name.

Do I need to sign in to Douyin?

No. It uses no account of yours, so it cannot affect your account.

Published: Last updated: