# TikTok User Posts Scraper — every video + stats (`mu0i/tiktok-user-posts`) Actor

Every video an account has posted, one row each, with play counts, likes, hashtags and a no-watermark link. Date ranges seek directly instead of walking from the top.

- **URL**: https://apify.com/mu0i/tiktok-user-posts.md
- **Developed by:** [Mu0i](https://apify.com/mu0i) (community)
- **Categories:** Social media, Videos, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 videos

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### TikTok User Posts Scraper — every video + stats

Give it handles, profile URLs or user IDs. Get **one row per video**: play count, likes, comments, shares,
saves, caption, hashtags, mentions, sound, and a direct no-watermark link.

No login, no cookies, no browser.

### A date range costs only the pages inside it

Most scrapers page from the newest post down to the window you asked for and charge you for everything they
walked past. Here the cursor is a timestamp, so **`postedBefore` seeks straight to that date**.

Asking for posts before 2025-06-01 on an account with years of history returned 40 posts dated
**2025-04-22 to 2025-05-30 in two pages** — it did not start at 2026 and work down.

### Pinned posts, and why they matter to a date range

Pinned posts are returned **first regardless of age**. On one account, page one ran from 2026-08-11 down to a
pinned post from **2023-11-16**. A scraper that applies your date cutoff naively stops there, on the first page,
with almost nothing collected.

This Actor exempts pinned posts from the date bounds, so the walk continues to the real cutoff. Every row is
flagged `isPinned`, and `includePinned: false` leaves them out entirely — which gives you a clean date window:

| | rows | dates |
|---|---|---|
| `postedAfter: 2026-07-01`, pinned included | 44 | 2023-11-16 … 2026-08-11 (three pinned) |
| the same, `includePinned: false` | 41 | 2026-07-01 … 2026-08-11 |

### How to use

1. Click **Try for free** at the top of this page. Apify creates a free account if you do not have one — no card is needed to run this.
2. Put what you want scraped into **Profiles** — one per line.
3. Set **Max posts per profile** to bound the run, then press **Start**. You are billed per row, so this field is also your budget.
4. Rows show up in the **Dataset** tab *while the run is still going*. Export to JSON, CSV, Excel or XML from there, or read them over the API.

### Input

| field | | |
|---|---|---|
| `profiles` | required | `@nasa`, `nasa`, `https://www.tiktok.com/@nasa`, a `sec_uid`, or a numeric user ID |
| `maxPostsPerProfile` | 100 | Set it high to take everything — the walk reaches the end and stops |
| `postedAfter` | — | ISO date. Stops as soon as posts are older than this |
| `postedBefore` | — | ISO date. **Starts** the walk here instead of at the newest post |
| `includePinned` | on | Pinned posts ignore your date range by nature; turn off to exclude them |
| `includeDownloadUrls` | on | No-watermark link per row, free — it is in the same response |

Every field, with its default — paste the whole block and delete what you do not need:

```json
{
  "profiles": [
    "@nasa"
  ],
  "maxPostsPerProfile": 100,
  "postedAfter": "",
  "postedBefore": "",
  "includePinned": true,
  "includeDownloadUrls": true
}
```

### Output

| field | |
|---|---|
| `videoId`, `url`, `description`, `createdAt`, `durationMs`, `width`, `height` | |
| `playCount`, `likeCount`, `commentCount`, `shareCount`, `saveCount`, `repostCount`, `downloadCount` | |
| `isPinned`, `isPhotoPost`, `region` | |
| `hashtags[]`, `mentions[]` | mentions carry `userId` and `secUid` |
| `musicId`, `musicTitle`, `musicAuthor` | |
| `coverUrl`, `dynamicCoverUrl` | |
| `noWatermarkUrl`, `noWatermarkSize` | when enabled |
| `authorUsername`, `authorNickname`, `authorId`, `authorSecUid` | |

One row, exactly as it lands in your dataset (long signed CDN links shortened here for readability):

```json
{
  "videoId": "7673631102036184334",
  "url": "https://www.tiktok.com/@natgeo/video/7673631102036184334",
  "description": "As the moon's shadow swept across Europe on August 12, the continent saw its first total solar eclipse in 27 years—but nowhere had a view quite as dramatic as Spain. National Geographic photographer R …",
  "createdAt": "2026-08-13T21:28:15.000Z",
  "isPinned": false,
  "isPhotoPost": false,
  "playCount": 9086,
  "likeCount": 665,
  "commentCount": 14,
  "shareCount": 1,
  "saveCount": 14,
  "repostCount": 0,
  "downloadCount": 0,
  "durationMs": 23315,
  "width": 576,
  "height": 1024,
  "coverUrl": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-p-0068-tx/oIsebU3…?…",
  "dynamicCoverUrl": "https://p19-common-sign.tiktokcdn-us.com/tos-useast5-p-0068-tx/oUAaHIv…?…",
  "hashtags": [],
  "mentions": [],
  "musicId": "7673631195946617613",
  "musicTitle": "original sound - natgeo",
  "musicAuthor": "National Geographic",
  "region": "EC",
  "authorUsername": "natgeo",
  "authorNickname": "National Geographic",
  "authorId": "6780344874811442181",
  "authorSecUid": "MS4wLjABAAAAEf96k3JW8-3eOhgzgQswlFF6ZDnn1dzqWWorJjwDsiNZymqTtvOcFhp_RiYYST6s",
  "noWatermarkUrl": "https://v45.tiktokcdn-us.com/95c9bfae1f0cb7287f62086d6b69caf4/6a7fc18a…?…",
  "noWatermarkSize": 348422
}
```

### Notes

- **`url` is TikTok's own canonical link.** A photo post therefore points at `/photo/` and a video at
  `/video/`, and a row whose author handle is missing gets `null` rather than a link that would 404.
- **Completeness.** This is the most reliable pagination on TikTok's public surface: walked to the end it
  returned 230 videos across 12 pages with **zero duplicates**, and it stops cleanly rather than looping.
- **No-watermark links are free here** — the same response carries them, so there is no per-video surcharge.
  They are signed TikTok CDN links and expire within hours; if you need the files kept, use the **TikTok Video
  Downloader** actor, which stores them and also handles photo-post images.
- Photo posts (slideshows) appear as rows flagged `isPhotoPost`. Their individual images are not here — the
  downloader actor has those.
- Private accounts return no posts. A handle that does not exist is logged and skipped; other accounts in the
  same run are unaffected.
- Only public data. There is no login, so nothing hidden from a logged-out visitor is reachable.

#### Run it from your own code

Every Actor is an API endpoint. This starts a run, waits for it, and returns the rows in one call — swap in your token from **Settings → Integrations**:

```bash
curl -X POST 'https://api.apify.com/v2/acts/mu0i~tiktok-user-posts/run-sync-get-dataset-items?token=YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
    "profiles": [
      "@nasa"
    ],
    "maxPostsPerProfile": 100,
    "postedAfter": "",
    "postedBefore": "",
    "includePinned": true,
    "includeDownloadUrls": true
  }'
```

### Pricing

Pay per result — you are billed for rows you receive, not for time or compute.

| Event | Per 1,000 | What one unit is |
|---|---:|---|
| `video` | $2.50 | one video in the dataset |

**Paid Apify plans pay less than this.** The table above is the free-plan rate. Starter, Scale and Business each get a lower per-unit price — up to **60% off** on Business — and the Actor's Pricing tab shows every tier before you run anything.

**Starting a run costs $0.00001** — a cent per thousand runs — and there is no run minimum. **You are never billed for a run that found nothing.** If an input has nothing to collect the run says so
in a row of the dataset — never a silently empty result, and never a charge. A run that fails because the
data could not be *reached* fails loudly, because that one is worth retrying.

### Related Actors

Fourteen Actors covering the whole public TikTok surface. Same billing rules and the same guarantees throughout: billed once for each row you receive, never billed for a run that found nothing, and told in the dataset why it found nothing.

| Actor | What it does |
|---|---|
| [TikTok Search Scraper — videos, users, hashtags](https://apify.com/mu0i/tiktok-search-scraper) | Keyword search across every tab, deduplicated. |
| [TikTok Hashtag Scraper — videos by hashtag](https://apify.com/mu0i/tiktok-hashtag-scraper) | Every video under a hashtag, walked deep. |
| [TikTok Trending Scraper — the real Explore feed](https://apify.com/mu0i/tiktok-trending) | The app's real Explore feed, not Creative Center. |
| [TikTok Profile Scraper — followers, likes, bio](https://apify.com/mu0i/tiktok-profile-scraper) | Followers, likes, bio for any public account. |
| [TikTok Comments Scraper — replies, no duplicates](https://apify.com/mu0i/tiktok-comments-scraper) | Every comment and reply, no duplicate pages. |
| [TikTok Video Downloader — no watermark MP4/MP3](https://apify.com/mu0i/tiktok-video-downloader) | No-watermark MP4, MP3, covers and subtitles. |
| [TikTok Transcript Scraper — no AI, no waiting](https://apify.com/mu0i/tiktok-transcripts) | Subtitles from TikTok's own caption track. |
| [TikTok Sound Scraper — videos using a sound](https://apify.com/mu0i/tiktok-sound-scraper) | Videos that actually use a sound, filtered. |
| [TikTok Live Scraper — rooms, viewers, streams](https://apify.com/mu0i/tiktok-live-scraper) | Live rooms with playable stream links. |
| [TikTok Places Scraper — locations and reviews](https://apify.com/mu0i/tiktok-places-scraper) | Locations with addresses, coordinates and reviews. |
| [TikTok Shop Scraper — Products, Sellers & Reviews](https://apify.com/mu0i/tiktok-shop-scraper) | Shop search, product detail, seller catalogue. |
| [TikTok Shop Category Scraper — every product](https://apify.com/mu0i/tiktok-shop-category-scraper) | Every product in a Shop category and its subcategories. |
| [TikTok Shop Reviews Scraper — full archive](https://apify.com/mu0i/tiktok-shop-reviews-scraper) | The full review archive for a Shop product. |

# Actor input Schema

## `profiles` (type: `array`):

Any of: @nasa, nasa, https://www.tiktok.com/@nasa, a sec\_uid (MS4wLjABAAAA…), or a numeric user id. One per line.

## `maxPostsPerProfile` (type: `integer`):

The walk stops here, or when the account runs out — whichever comes first. Set it high to take everything: pagination on this endpoint reaches the end cleanly.

## `postedAfter` (type: `string`):

ISO date, e.g. 2026-01-01. The walk stops as soon as it reaches posts older than this, so a narrow window costs only the pages inside it.

## `postedBefore` (type: `string`):

ISO date, e.g. 2026-06-30. Starts the walk at that date rather than at the newest post.

## `includePinned` (type: `boolean`):

Pinned posts appear first regardless of age, so they may fall outside your date range. Turn this off to exclude them.

## `includeDownloadUrls` (type: `boolean`):

Adds a direct no-watermark video link to each row at no extra cost — it is in the same response. TikTok CDN links are signed and expire within hours; for saved files use the TikTok Video Downloader actor.

## Actor input object example

```json
{
  "profiles": [
    "@nasa"
  ],
  "maxPostsPerProfile": 100,
  "includePinned": true,
  "includeDownloadUrls": true
}
```

# Actor output Schema

## `results` (type: `string`):

Every video the profiles posted, with stats.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "profiles": [
        "@nasa"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("mu0i/tiktok-user-posts").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "profiles": ["@nasa"] }

# Run the Actor and wait for it to finish
run = client.actor("mu0i/tiktok-user-posts").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "profiles": [
    "@nasa"
  ]
}' |
apify call mu0i/tiktok-user-posts --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,mu0i/tiktok-user-posts"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/BDvixcsTxi9z6Ogje/builds/SeO9886Poj5sxPzGg/openapi.json
