# RedNote (Xiaohongshu) Notes Scraper (`nice_dev/rednote-notes-scraper`) Actor

Scrape RedNote (Xiaohongshu) notes from trending categories, note and profile links (no login), or by keyword and with comments using your own cookie: full text, exact counts, tags, images, video, author. Export to JSON, CSV or Excel.

- **URL**: https://apify.com/nice_dev/rednote-notes-scraper.md
- **Developed by:** [Nice Dev](https://apify.com/nice_dev) (community)
- **Categories:** Social media, MCP servers
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.78 / 1,000 notes

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/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### 📕 What is RedNote (Xiaohongshu) Notes Scraper?

**RedNote (Xiaohongshu) Notes Scraper** extracts **notes from [RedNote / Xiaohongshu](https://www.xiaohongshu.com) (小红书)**: **the full text with its hashtags, like / save / comment / share counts, every image in high resolution, the video, the publication date, the IP location and the author**, from trending categories, note links, profiles and keyword searches. It works as a **RedNote API alternative**: run it on a schedule, call it from your code, or plug it into Make, Zapier or n8n.

Pick a **trending category** or paste **note links** and **profile links**, click **Start**, and download the notes in JSON, CSV or Excel: no account needed for those. Add **your own RedNote cookie** to also search by keyword, collect comments and replies, list the notes of a profile and get keyword suggestions. Each note comes with its **whole text in the same row**, not a preview cut after a few words.

### 📋 What data can you extract from RedNote?

One item per note, comment, profile or keyword suggestion, 52 fields:

| Category | What you get |
| --- | --- |
| 📝 **Note** | title, full text with hashtags, image or video note, link that opens without login — `冷门 ，但好用到起飞🛫️` |
| ❤️ **Engagement** | likes, saves, comments and shares as the note's page prints them (exact up to 9 999, rounded above: `3.8万` = `38000`) — `207 likes, 82 saves` |
| 🖼️ **Images and video** | every image in high resolution with its size, cover, video link and length, copies kept in your run's storage |
| 🏷️ **Topics** | hashtags and the users tagged with @ |
| 🕒 **Dates and place** | publication date, last update, the province or country RedNote shows (IP location) |
| 👤 **Author** | name, id, avatar and profile link of the author of each note |
| 🧑‍🤝‍🧑 **Profiles** | RedNote number (小红书号), bio, gender, followers, following, likes and saves received, notes posted, verification |
| 💬 **Comments** | comment text, likes, date, IP location, author, pictures, replies with the comment they answer |
| 🔥 **Trending and search** | the category or keyword that found the note, its rank on the page (1 = first) |
| 🔎 **Keyword suggestions** | the keywords RedNote suggests for each search keyword |

Every field, with an example, is listed in the **Output** section below.

Notes found in a trending category, a search or a profile come with what the list shows (title, cover, author, likes as RedNote rounds them, e.g. 3.8万). Tick **Full note details** for the full text, every image, the page's counts, tags, IP location and dates. Notes from **Note URLs** always have them.

### ✅ Why use RedNote (Xiaohongshu) Notes Scraper?

- 📖 **The whole note in one row**: full text, counts, tags, IP location, last update and every image, not a preview cut after a line.
- 🔥 **Trending notes by category**: recommended, fashion, food, beauty and travel, each note with its rank on the page.
- 🧩 **All of RedNote in one Actor**: notes, comments and replies, author profiles, notes of a profile and keyword suggestions, each one a row of the same dataset.
- 🔓 **No account for links, trending and profiles**: your own cookie is only needed for search, comments, profile notes and suggestions.
- 🖼️ **Images and videos kept**: tick **Download images** / **Download videos** and the files are copied into your run's storage, with their links in the note.
- 🔔 **Monitoring built in**: tick **Only new notes**, schedule the Actor, and each run returns (and charges) only the notes it has never delivered before (keyword suggestions and author profiles are delivered again by each run).
- 🎯 **Filters**: publication date, minimum likes or comments, excluded words.
- 🔌 API, scheduling, monitoring, integrations (Make, Zapier, n8n, Google Sheets…), proxy rotation and JSON/CSV/Excel export via the Apify platform.

### 🚀 How to scrape RedNote

1. Create a free Apify account.
2. Open **RedNote (Xiaohongshu) Notes Scraper** and pick one or more **Trending categories**, or paste **Note URLs** (as copied from the browser or the app) and **Profile URLs**.
3. To search by keyword, collect comments or list the notes of a profile, paste **your own RedNote cookie** into **RedNote cookie** and type a **Search keyword** (e.g. `咖啡` or `coffee`).
4. Set **Max notes** (100 by default, 0 = no limit), tick the extra data you want (full details, comments, author profiles, images), then click **Start**.
5. Download the dataset in JSON, CSV, Excel or via API.

### 💰 How much does it cost to scrape RedNote?

This Actor uses **pay per event** pricing: a price per note saved, plus a small fee per run start. Full note details, comments, profiles, keyword suggestions, images and videos are options, off by default, each charged by its own event: leave them unticked to pay for the notes alone.

| Apify plan | Note | Trending note | Full note details | Profile | Comment or reply | Keyword suggestion | Image kept | Video kept | Note dropped by a filter | Note dropped after its page |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Free | **$0.81** | **$0.79** | **$2.69** | **$1.79** | **$1.39** | **$0.89** | **$1.79** | **$4.49** | **$0.039** | **$0.18** |
| Bronze | $0.80 | $0.78 | $2.68 | $1.69 | $1.19 | $0.81 | $1.59 | $3.99 | $0.029 | $0.17 |
| Silver | $0.79 | $0.77 | $2.67 | $1.59 | $1.09 | $0.72 | $1.49 | $3.79 | $0.019 | $0.16 |
| Gold | $0.78 | $0.76 | $2.66 | $1.49 | $0.89 | $0.63 | $1.39 | $3.59 | $0.01 | $0.15 |

Prices per 1,000, plus **$0.01 per run start** ($1 per 100 runs). Platform usage (compute, proxy) is included in the price. Example on the Free plan: 1,000 note links ≈ $0.82; 1,000 trending notes with their full details ≈ $3.49.

- **Note** = a note from a note link (its full page is included), a search or a profile; **Trending note** = a note card from a trending category. Notes already delivered (**Only new notes**) are not charged again.
- **Full note details** is charged only for a note found in a trending feed, a search or a profile whose page was read; never for a note link.
- **Image kept** / **Video kept**: one per file copied to the run's storage. A file that is too large, gone or not of the expected type is not saved and not charged.
- **Comment or reply** and **Keyword suggestion** rows, the search and the notes of a profile need your own RedNote cookie.
- The filters RedNote does not apply itself (dates, minimum likes or comments, excluded words) are checked by the Actor on every note it reads: a note you keep costs its normal price; a note a filter drops costs only **Note dropped by a filter**, or **Note dropped after its page** when the filter needed the note's page.

### ⚙️ Input

Trending notes with their full details, no account needed:

```json
{
    "categories": ["homefeed_recommend", "homefeed.food_v3"],
    "maxItems": 50,
    "includeNoteDetails": true
}
```

Note and profile links, with the author profiles and a copy of the images:

```json
{
    "noteUrls": [
        "https://www.xiaohongshu.com/explore/64b806f600000000230346e0?xsec_token=AB5nijiA-VcXeOH2WmPaQCYEcs0bKy5lhoXcjxMsXPtVM=&xsec_source=pc_feed"
    ],
    "profileUrls": ["5fca51a2000000000100ab9d"],
    "includeAuthorProfile": true,
    "downloadImages": true
}
```

With your cookie: several searches, newest first, comments, only the notes of the last week not delivered before (the date needs the full note details):

```json
{
    "cookie": "a1=YOUR_A1; webId=YOUR_WEBID; web_session=YOUR_WEB_SESSION",
    "searchQueries": ["咖啡", "coffee"],
    "sortType": "time_descending",
    "maxItemsPerQuery": 100,
    "includeNoteDetails": true,
    "includeComments": true,
    "maxCommentsPerNote": 50,
    "postedAfter": "7 days",
    "onlyNew": true,
    "stateKey": "coffee-notes"
}
```

| Field | Notes |
| --- | --- |
| `query`, `searchQueries` | Keywords in Chinese or English (`咖啡`, `coffee`), one search each (max 100 searches per run). Needs your `cookie`. |
| `categories` | Trending notes: `homefeed_recommend` (recommended), `homefeed.fashion_v3`, `homefeed.food_v3`, `homefeed.cosmetics_v3`, `homefeed.travel_v3`. About 20-32 notes per category each time it is read, with their rank. No account needed. |
| `noteUrls` | Note links as copied from the browser or the app, with their access token (`https://www.xiaohongshu.com/explore/64b806f600000000230346e0?xsec_token=AB5nijiA-VcXeOH2WmPaQCYEcs0bKy5lhoXcjxMsXPtVM=`), or short xhslink.com share links. A link without its token cannot be opened and is reported in the log. Max 1,000 links. No account needed. |
| `profileUrls`, `maxNotesPerProfile` | Profile links or user IDs (`5fca51a2000000000100ab9d`), one profile result each; `maxNotesPerProfile` also saves the notes each profile posted, newest first (needs your `cookie`). Max 1,000 profiles. |
| `maxItems`, `maxItemsPerQuery` | Notes saved for the whole run (`0` = unlimited), and for EACH keyword, category or profile. Comments, profiles and suggestions are not counted. |
| `sortType`, `noteType`, `timeFilter` | RedNote's own search options: order (`general`, `time_descending`, `popularity_descending`, `comment_descending`, `collect_descending`), only video or only image notes, published within a day, a week or half a year. |
| `cookie` | The cookie of your own logged-in RedNote account, copied from your browser on xiaohongshu.com: the whole `Cookie` header, or at least `a1`, `webId` and `web_session`. Unlocks search, comments, profile notes and keyword suggestions; without it they are skipped and the log says so. Stored encrypted. Use a secondary account. |
| `includeNoteDetails` | Open each note found by search, trending or a profile for its full text, every image, the page's counts, tags, mentioned users, IP location and last update (default off). |
| `includeComments`, `maxCommentsPerNote`, `includeReplies`, `maxRepliesPerComment` | One result per comment (20 per note by default) and per reply (10 per comment by default), 0 = all. Needs your `cookie`. |
| `includeAuthorProfile` | Also save the profile of each note author, once per run. |
| `downloadImages`, `downloadVideos` | Copy the images (up to 20 per note, the cover only for a note without its details) and the videos into the run's key-value store, with their links in the note. Charged per file saved. |
| `suggestKeywords` | One result per keyword RedNote suggests for each search keyword. Needs your `cookie`. |
| `postedAfter`, `postedBefore` | Publication date range: `2026-09-01` (counted in Beijing time, UTC+8), or a period before now (`7 days`, `2 weeks`, `1 month`, `24 hours`). Needs `includeNoteDetails` for notes found by category, search or profile. |
| `excludeKeywords` | Drop the notes whose title, and text with Full note details, contains one of these words (case and accents ignored). Without `includeNoteDetails`, only the title of a note found by category, search or profile is read. |
| `minLikes`, `minComments` | Drop the notes with fewer likes or comments; the comment count needs `includeNoteDetails` for notes not given in `noteUrls`. |
| `onlyNew`, `stateKey`, `resetState` | Monitoring: only the notes never delivered under this memory key; `resetState` forgets the memory. |
| Advanced | `proxyConfiguration` (Apify proxy by default, included in the price; the residential proxy is not available), `maxConcurrency`, `maxRequestsPerMinute`, `minRequestIntervalMs`, `maxRequestRetries`, `debugLog`. |

### 📦 Output

A trending note with its full details, from a test run (shortened: the empty profile and comment fields are left out):

```json
{
    "recordType": "note",
    "id": "64b806f600000000230346e0",
    "url": "https://www.xiaohongshu.com/explore/64b806f600000000230346e0?xsec_token=AB5nijiA-VcXeOH2WmPaQCYEcs0bKy5lhoXcjxMsXPtVM=&xsec_source=pc_feed",
    "noteId": "64b806f600000000230346e0",
    "xsecToken": "AB5nijiA-VcXeOH2WmPaQCYEcs0bKy5lhoXcjxMsXPtVM=",
    "title": "冷门 ，但好用到起飞🛫️",
    "description": "vc面霜 丝绒的质感\n橘子味 油皮慎用#冷门[话题]#",
    "noteType": "image",
    "publishedAt": "2023-07-19T15:53:26.000Z",
    "lastUpdatedAt": "2023-07-19T15:53:27.000Z",
    "likedCount": 207,
    "likedCountText": "207",
    "collectedCount": 82,
    "commentCount": 20,
    "shareCount": 5,
    "tags": ["冷门"],
    "mentionedUsers": [],
    "images": [
        "http://sns-webpic-qc.xhscdn.com/202610160926/002f2aaddccaf457751d3950455ba107/1000g0082qtkc42uk80005nuaa6h09astt24klq0!nd_dft_wlteh_webp_3"
    ],
    "imageCount": 1,
    "coverWidth": 1440,
    "coverHeight": 1920,
    "hasVideo": false,
    "videoUrl": null,
    "storedMedia": null,
    "authorId": "5fca51a2000000000100ab9d",
    "source": "trending",
    "searchQuery": null,
    "category": "homefeed.cosmetics_v3",
    "rank": 1,
    "scrapedAt": "2026-10-16T01:26:09.889Z"
}
```

You can download the dataset in various formats such as JSON, HTML, CSV or Excel.

#### All 52 fields

| Fields | What you get |
| --- | --- |
| `recordType`, `id`, `source` | `note`, `comment`, `profile` or `keyword`; RedNote id (the keyword itself for a suggestion); how it was found: `search`, `trending`, `noteUrl`, `profile`, `comment`, `author` or `suggestion` |
| `url`, `noteId`, `xsecToken` | **Note**: page that opens without login (for a comment, its note's page; for a profile, the profile page), note id, access token |
| `title`, `description`, `noteType` | title, full text with hashtags (comment text, profile bio), `image` or `video` |
| `publishedAt`, `lastUpdatedAt`, `ipLocation` | **Dates and place**: ISO 8601 UTC dates (what the date filters read), province or country shown by RedNote |
| `likedCount`, `likedCountText`, `collectedCount`, `commentCount`, `shareCount` | **Engagement**: `207`, `207` as displayed (`3.8万` on a card = `38000`), saves, comments, shares |
| `tags`, `mentionedUsers` | hashtags, users tagged with @ (`userId`, `nickname`) |
| `coverUrl`, `coverWidth`, `coverHeight` | cover picture and its size |
| `images`, `imageCount`, `imageList` | every image URL, how many, one object per image (`url`, `width`, `height`, `livePhoto`) |
| `hasVideo`, `videoUrl`, `videoDuration` | video note or not, video link, length |
| `storedMedia` | links to the images / video copied into the run's key-value store (`downloadImages`, `downloadVideos`) |
| `authorId`, `authorName`, `authorAvatarUrl`, `authorUrl` | **Author** of the note or comment |
| `parentCommentId`, `replyCount` | **Comments**: the comment a reply answers (`null` for a top-level comment), number of replies |
| `redId`, `nickname`, `avatarUrl`, `gender`, `verified`, `verifyType` | **Profiles**: RedNote number (小红书号), name, picture, `male` / `female` / `null`, verified or not, `personal` or `business` |
| `followerCount`, `followerCountText`, `followingCount`, `followingCountText` | followers (RedNote rounds large counts: `1万+` = `10000`) and following, as numbers and as displayed |
| `likesAndCollects`, `likesAndCollectsText`, `noteCount` | likes plus saves received, notes posted |
| `searchQuery`, `category`, `rank` | **Trending and search**: keyword that found the note (or that a suggestion belongs to), trending category, position on the page (1 = first) |
| `scrapedAt` | ISO timestamp of the extraction |

### 💡 Tips

#### How to get more results

Set `maxItems` to `0`, pick several trending categories and schedule the Actor: the feeds change through the day. With your cookie, add several keywords to `searchQueries` and try each `sortType`: each order brings other notes.

#### How to reduce costs

The price is per result, so the levers are `maxItems`, `maxItemsPerQuery`, the extra data you tick (full details, comments, profiles, files), the filters (a filtered-out note costs only the filter fee) and `onlyNew` for recurring runs (you never pay twice for the same note). Keep `maxCommentsPerNote` and `maxRepliesPerComment` low when you only need a sample of the conversation.

#### Search, comments and profile notes with your cookie

Log in to www.xiaohongshu.com in your browser with a secondary account, copy the `Cookie` header of a page of the site, and paste it into **RedNote cookie**. The Actor then reads with your account, at a visitor's pace, what RedNote shows it. Keep the run's memory at 1 GB or more (the default): below that, the sources that need the cookie are skipped with a warning in the log, and the others run as usual.

#### Several searches in one run

Fill `searchQueries`: the Actor runs one search per keyword, up to 100 per run. The single `query` field still works and is added to the list. A note found by several searches, categories or profiles is saved — and charged — once. Set `maxItemsPerQuery` to give every search, category and profile its own cap: without it the first ones can use up the whole `maxItems` budget.

#### Keep the images and videos

The image and video links RedNote gives are links to its own servers, made for showing the note now. To keep the files, tick `downloadImages` / `downloadVideos`: each file is copied into the run's key-value store and its link added to `storedMedia`. A file over 10 MB for an image or 50 MB for a video (5 MB and 10 MB when the run has less than 1 GB of memory) is not saved and not charged.

#### Monitoring: only the new notes

Tick **Only new notes** (`onlyNew`) and schedule the Actor. The first run returns everything; each later run skips the notes already delivered: they are not saved, not charged, and their page is not even opened. The memory lives in a named key-value store of your account (`rednote-notes-scraper-seen`, up to 150,000 notes per key) and is only updated with notes that really reached the dataset, so a failed run never hides anything. Give each schedule its own `stateKey` (two schedules sharing a key would hide each other's notes), and tick `resetState` once to start over.

#### Filter by publication date

`postedAfter` and `postedBefore` take a date (`2026-09-01`, the whole day is included) or a period before now (`7 days`, `2 weeks`, `1 month`; via the API also `24 hours` or a full ISO date-time). A date alone is counted in Beijing time (UTC+8). The filter reads `publishedAt`, which RedNote gives on the note's page: it needs **Full note details** for category, search and profile notes (without it, those notes are not filtered by date). A note without a publication date is dropped as soon as a date bound is set. Filtered-out notes are not saved and do not count in `maxItems` (each note dropped costs the filter fee, see Pricing); the run summary tells how many were filtered. For searches, RedNote's own `timeFilter` (a day, a week, half a year) narrows the results before they are read.

### 🔌 Integrations and API

Call the Actor via the Apify API, the JavaScript or Python clients, or connect it with integrations and webhooks (Make, Zapier, n8n, Google Sheets, Slack, Airtable…). The dataset can be fetched as JSON or CSV from any tool.

### 🤖 Use with AI agents (MCP)

AI agents (Claude, ChatGPT, Cursor…) can find and run this Actor through the [Apify MCP server](https://mcp.apify.com), billed to their Apify account like any run. It returns one item per RedNote note (plus comments, profiles or keyword suggestions when asked). Actor id: `nice_dev/rednote-notes-scraper`; MCP server with this Actor only: `https://mcp.apify.com/?tools=fetch-actor-details,nice_dev/rednote-notes-scraper`.

Smallest input, for a cheap first call:

```json
{
    "categories": ["homefeed_recommend"],
    "maxItems": 10
}
```

Key output fields: `url`, `title`, `description`, `likedCount`, `publishedAt`, `images`, `authorName` and `rank`.

Cost: per result saved, at the prices of the pricing section above. Cap each call with `maxItems` and, through the API, with the run option `maxTotalChargeUsd`.

### ❓ FAQ

#### Is it legal to scrape RedNote?

Without a cookie, the Actor only reads what RedNote shows publicly to any anonymous visitor, and logs in to nothing. With your cookie, it reads with your own account the public notes, comments and profiles RedNote shows you, and only reads. Results can contain personal data (names, profile details, comments), which is protected by GDPR and other privacy laws: do not store it without a legitimate reason. You are responsible for using the data, and your account, in compliance with RedNote's Terms of Use and applicable law. This Actor is not affiliated with RedNote or Xiaohongshu.

#### Does it need a login or a proxy?

No login for trending categories, note links and profiles. Search, comments, the notes of a profile and keyword suggestions need the cookie of your own RedNote account (see Tips). The proxy is included in the price: leave the default setting (the residential proxy is not available). A request the site turns away is retried at once on a new proxy session, up to 10 times on top of the retries (without a proxy, after a pause of 5 seconds, doubled at each retry up to 150 seconds).

#### Is the data safe to open in Excel or to show on a web page?

Titles, texts and comments are the authors' own words, copied as they are. A text can begin with `-`, `+`, `=` or `@` (a tagged user, a title such as `-50% today`): Excel and Google Sheets may read such a cell of a CSV file as a formula or as a number. The Actor leaves the text as it is, so that the JSON and the API give the real value: when you open a CSV, import these columns as text. On a web page, escape every field like any text written by a stranger.

#### Known limitations

- Notes from a category, a search or a profile have the list's data only (likes rounded, no full text) unless **Full note details** is on.
- RedNote prints a count of 10 000 or more rounded, on the note's page as on the list (`3.8万` likes = `38000`, `1.3万` saves = `13000`): no option gives the exact number. Followers of a profile are printed as a floor (`1万+` = `10000`, `1千+` = `1000`); likes plus saves of a profile are exact.
- A note link without its access token cannot be opened by RedNote: copy the whole link, or the short xhslink.com share link.
- Categories hold the notes RedNote recommends in each of 5 categories: recommended, fashion, food, beauty and travel. They are often not recent (the food category can serve notes from years ago): read the date with Full note details.
- The image and video links point to RedNote's servers: use `downloadImages` / `downloadVideos` to keep the files.
- `onlyNew` remembers note ids, not their content: a note whose counts changed is not returned again.
- Two runs sharing the same `stateKey` at the same time may both return the same new note.

**A run that reaches its timeout** stops itself about 45 seconds before it: no new page is asked, what it read is saved and, with `onlyNew`, remembered, and the run ends *Succeeded* with "Stopped before the run's timeout". Resurrect it to go on from there, or give the next run a longer timeout (Run options).

**A run the platform stops without warning** (out of memory)

- Resurrect it: it goes on from where it stood at most a minute before the stop. What it had read since is read again, and the notes already saved are skipped: none is delivered or charged twice, and `maxItems` still counts them.
- With `onlyNew`, the memory is saved after each write (at most once every 2 seconds): resurrect the stopped run and the notes it had saved meanwhile join the memory; leave it stopped for good, and the next run may return the notes of its last 2 seconds once more.

#### Something doesn't work?

The last line of the log counts the notes saved, filtered out and no longer on RedNote (removed while the run was reading them), and the requests that failed after every retry. Those requests and the removed notes are listed, with the reason, in the `FAILED_REQUESTS` record of the run's key-value store. A run that saved nothing and had failed requests fails, and its last message gives the cause. With a cookie, a skipped source (no cookie, not enough memory) is named in the log.

If RedNote changes its pages, you are told instead of paying for blank rows. If the first 20 notes read all lack their title, access token, author or like count — or, read on the note's page, their text, publication date or comment count — the run saves nothing more, stops and fails, and its last message names the missing field: at most those first notes are charged. A note that `postedAfter` / `postedBefore` drops because it has no date at all counts among those 20. A run of fewer notes (a scheduled `onlyNew` run that finds a few new ones, a small **Max notes**) is checked at its end, from 5 notes: its notes are already saved, and the run fails with the missing field instead of ending green.

### 🛟 Support

Open an issue in the **Issues** tab with a link to your run: the run log and the `FAILED_REQUESTS` record of the key-value store show exactly which URLs failed and why.

# Actor input Schema

## `query` (type: `string`):

Keyword searched on RedNote, in Chinese or English (e.g. `咖啡` or `coffee`). Each search returns the notes in the order chosen in **Sort by**.

## `searchQueries` (type: `array`):

Several keywords in one run: one search per keyword. Added to **Search keyword**; notes found by several searches are saved once.

## `categories` (type: `array`):

Notes RedNote recommends on its Explore page, per category (about 20-32 notes per category and read). They are often not recent: read the date with **Full note details**. Each note is saved with its category and its rank on the page.

## `noteUrls` (type: `array`):

RedNote note links, as copied from the browser or the app: `https://www.xiaohongshu.com/explore/<id>?xsec_token=...`, `https://www.xiaohongshu.com/discovery/item/<id>?xsec_token=...` or short `https://xhslink.com/...` share links. A link without its `xsec_token` cannot be opened by RedNote and is reported in the log. Max 1 000 links.

## `profileUrls` (type: `array`):

RedNote profile links (`https://www.xiaohongshu.com/user/profile/<id>`) or bare user IDs (24 hex characters). Each one gives a profile result; set **Max notes per profile** to also get the notes it posted. Max 1 000.

## `maxItems` (type: `integer`):

Maximum number of notes to save for the whole run (after deduplication and filters). Comments, profiles and keyword suggestions are not counted here. 0 = no limit.

## `maxItemsPerQuery` (type: `integer`):

Cap for EACH keyword and each trending category, so that the first one cannot use up the whole **Max notes** budget. 0 = no per-search cap.

## `sortType` (type: `string`):

Order of the search results, as on RedNote.

## `noteType` (type: `string`):

Search only video notes or only image notes.

## `timeFilter` (type: `string`):

RedNote's own date filter for the search. For an exact date range use **Posted after** / **Posted before** below.

## `maxNotesPerProfile` (type: `integer`):

Notes posted by each profile of **Profile URLs**, newest first; **Max notes per search** caps each profile too, the lower one wins. 0 = the profile only.

## `cookie` (type: `string`):

Cookie of your own logged-in RedNote account, copied from your browser on www.xiaohongshu.com (the whole `Cookie` header, or at least `a1`, `webId` and `web_session`). Needed for **Search keyword**, **Comments** and **Max notes per profile**; without it those are skipped and the log says so. Stored encrypted, used only to read public data at a visitor's pace. Use a secondary account. With a cookie the Actor runs a browser: keep at least 1 GB of memory (the default).

## `includeNoteDetails` (type: `boolean`):

For notes found by search, trending or a profile: open each note for its full text, every image in high resolution, like / save / comment / share counts, tags, mentioned users, IP location and last update date. Notes from **Note URLs** always have them.

## `includeComments` (type: `boolean`):

Also save the comments of each note (one result per comment: text, likes, date, IP location, author).

## `maxCommentsPerNote` (type: `integer`):

Top-level comments saved per note when **Comments** is on. 0 = all.

## `includeReplies` (type: `boolean`):

Also save the replies to each comment (marked with the id of the comment they answer).

## `maxRepliesPerComment` (type: `integer`):

Replies saved per comment when **Comment replies** is on. 0 = all.

## `includeAuthorProfile` (type: `boolean`):

Also save the profile of each note author once per run: bio, followers, likes and saves received, notes posted, verification, gender.

## `downloadImages` (type: `boolean`):

Save the images of each note in the run's key-value store and add the stored links to the note (field storedMedia). With **Full note details** (or a note from Note URLs): every image of the note, up to 20. Without it a note found in a list, a search or a profile has only its cover. A file that is too large, gone or not a picture is not saved and not charged. Charged per file saved.

## `downloadVideos` (type: `boolean`):

Save the video of each video note in the run's key-value store and add the stored link to the note (field storedMedia). Only a video note whose page was read has one: use **Full note details**, or a note from Note URLs. A video that is too large or gone is not saved and not charged. Charged per file saved.

## `suggestKeywords` (type: `boolean`):

Also save the keywords RedNote suggests while typing each search keyword (one result per suggestion).

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

Only notes published on or after this date (the note's publication date, not its last update): `2026-09-01`, or a period before now such as `7 days`, `2 weeks`, `1 month` (API: `24 hours` and full ISO date-times work too). A date alone is counted in Beijing time (UTC+8). For notes found by category, search or profile, turn on **Full note details**.

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

Only notes published on or before this date (the whole day is included, in Beijing time, UTC+8), or older than a period such as `30 days`. For notes found by category, search or profile, turn on **Full note details**.

## `excludeKeywords` (type: `array`):

Drop the notes whose title, and text with Full note details, contains one of these words (case and accents ignored). Without Full note details, only the title of a note found by category, search or profile is read.

## `minLikes` (type: `integer`):

Drop the notes with fewer likes. 0 = no minimum.

## `minComments` (type: `integer`):

Drop the notes with fewer comments (count read on the full note: needs **Full note details** for notes not given in Note URLs). 0 = no minimum.

## `onlyNew` (type: `boolean`):

Skip the notes that a previous run (same **Memory key**) already delivered: they are not saved and not charged, and their page is not even opened. First run = everything is new.

## `stateKey` (type: `string`):

Name of the memory used by **Only new notes**. Give each schedule / task its own key (e.g. `coffee-brands`) so that they do not share their memory. Letters, digits, `-` and `_`.

## `resetState` (type: `boolean`):

Forget everything remembered under this **Memory key** before the run: this run returns (and charges) every note again. Untick it afterwards.

## `proxyConfiguration` (type: `object`):

Apify Proxy or your own proxies. Keep the default: it is included in the price. The residential Apify proxy is not available in this Actor.

## `maxConcurrency` (type: `integer`):

Maximum number of requests processed in parallel.

## `maxRequestsPerMinute` (type: `integer`):

Most requests in any 60 seconds, all of them counted. A budget, not an even pace (spread them with the minimum delay below). Lower it if the log shows RedNote sending the Actor to its login or captcha page.

## `minRequestIntervalMs` (type: `integer`):

Smallest gap between two requests, in milliseconds. 0 = no gap.

## `maxRequestRetries` (type: `integer`):

Retries per request before it is marked as failed. Behind a proxy, a request RedNote turns away is also retried on a new IP up to 10 times without using up these retries.

## `debugLog` (type: `boolean`):

Include debug messages in the run log.

## Actor input object example

```json
{
  "searchQueries": [],
  "categories": [
    "homefeed_recommend"
  ],
  "noteUrls": [],
  "profileUrls": [],
  "maxItems": 100,
  "maxItemsPerQuery": 0,
  "sortType": "general",
  "noteType": "all",
  "timeFilter": "all",
  "maxNotesPerProfile": 0,
  "includeNoteDetails": false,
  "includeComments": false,
  "maxCommentsPerNote": 20,
  "includeReplies": false,
  "maxRepliesPerComment": 10,
  "includeAuthorProfile": false,
  "downloadImages": false,
  "downloadVideos": false,
  "suggestKeywords": false,
  "excludeKeywords": [],
  "minLikes": 0,
  "minComments": 0,
  "onlyNew": false,
  "stateKey": "default",
  "resetState": false,
  "proxyConfiguration": {
    "useApifyProxy": true
  },
  "maxConcurrency": 8,
  "maxRequestsPerMinute": 120,
  "minRequestIntervalMs": 0,
  "maxRequestRetries": 5,
  "debugLog": false
}
```

# Actor output Schema

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

No description

# 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 = {
    "categories": [
        "homefeed_recommend"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("nice_dev/rednote-notes-scraper").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 = {
    "categories": ["homefeed_recommend"],
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("nice_dev/rednote-notes-scraper").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 '{
  "categories": [
    "homefeed_recommend"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call nice_dev/rednote-notes-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,nice_dev/rednote-notes-scraper"
        }
    }
}
```

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/79FvPS7Rc3pYdru8T/builds/uheq572togVOfGqPw/openapi.json
