Urgent.News

What's breaking now, across thousands of outlets.

Tech

How to get Xiaohongshu (RedNote) data in Python

Disclosure: I built the Xiaohongshu Scraper used in this tutorial. It's a paid Actor on Apify (pay per result), and the pricing is listed at the end. Xiaohongshu (小红书), known abroad as RedNote, is where Chinese consumers go to decide what to buy. People post reviews, "what I bought" hauls, travel guides and café lists, and other people save those notes to come back to later. For brand research,…

Xiaohongshu (RedNote) is a popular platform in China where consumers share reviews, hauls, travel guides, and café lists. Due to its value for brand and product research, obtaining data from Xiaohongshu can be challenging. This tutorial focuses on extracting data from Xiaohongshu using Python in just 20 lines of code.

The script begins by setting up the environment, requiring Python 3.10 or higher and an Apify account. Replace 'your-token-here' with your personal Apify API token. Install necessary libraries using pip install apify-client pandas and export the API token as APIFY_TOKEN.

The search function starts by querying Xiaohongshu for a specified keyword, like 咖啡 (coffee). Chinese keywords are essential for obtaining accurate results. After running the search, the script loads the results into a pandas DataFrame and ranks the notes based on the save count (collects) versus like count. This ratio helps identify useful content, such as guides or reviews.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

40 Hours of Free SQL: Picking a Database on Cloudflare vs Azure as a Solo Founder

40 Hours of Free SQL: Picking a Database on Cloudflare vs Azure as a Solo Founder In my last post I priced the same small project on Cloudflare and Azure, round by round.

  • Cloudflare D1 requires only three steps to get a query running
  • Azure SQL Database involves several more steps, including firewall rule setup
  • Azure SQL Database provides 40 hours of free usage per month

Convert PDF pages to PNG in your browser without uploading the file

Convert PDF pages to PNG in your browser without uploading the file PDFs are convenient for sharing, but they are awkward when you need an image of a page.

  • Convert PDF pages to PNG without uploading file
  • PNG preserves sharp edges for text and diagrams
  • Tool runs locally, keeping PDF private

More from Tuesday 6 October →