# Telegram Channel Scraper & Monitor - Posts, Views, Reactions (`cheremikin/telegram-channel-scraper`) Actor

Scrape public Telegram channels without login: posts with text, date, views, reactions, media, links, hashtags, forwards and replies, plus channel info and subscribers. Date and keyword filters, only-new monitoring mode. Export to JSON, CSV or Excel.

- **URL**: https://apify.com/cheremikin/telegram-channel-scraper.md
- **Developed by:** [Alexandr Cheremikin](https://apify.com/cheremikin) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.50 / 1,000 post scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## Telegram Channel Scraper & Monitor - Export Posts, Views and Reactions to JSON, CSV or Excel

Scrape **public Telegram channels** without a Telegram account, phone number or API key. Get every post with its text, date, view count, reactions, photos and video thumbnails, links, hashtags, mentions, forwards and replies, plus channel info with the subscriber count. Use the **only new posts** mode to monitor channels on a schedule, and filter by date range or keywords. Download the results as JSON, CSV, Excel or HTML, or read them through the Apify API.

### What you get

One row per post (`type: "post"`), one optional channel row per channel (`type: "channel"`, free) and an error row (`type: "error"`, free) for channels that cannot be read.

| Field | Example | Notes |
|---|---|---|
| `channel` | `durov` | Channel username |
| `postId` | `558` | Message id inside the channel |
| `url` | `https://t.me/durov/558` | Link to the post |
| `date` | `2026-11-12T13:24:25+00:00` | Publish time, ISO 8601 (UTC) |
| `text` | `CORRECTION: Spy agencies are trying after all...` | Plain text, line breaks and emoji kept |
| `html` | `<b>700K+</b> self-custodial ...` | Only with **Include post HTML** |
| `views` / `viewsText` | `1610000` / `"1.61M"` | Telegram rounds large numbers (1.61M) |
| `reactions` | `[{"emoji": "⭐", "paid": true, "count": 4970}, {"emojiId": "5399847211989246390", "count": 23400}]` | `emoji` when the page shows the character, otherwise Telegram's `emojiId` |
| `reactionsTotal` | `43131` | Sum of reaction counts |
| `edited` | `false` | Post was edited |
| `forwardedFrom` | `{"name": "Медуза — все новости", "url": "https://t.me/meduza_news/96032", "channel": "meduza_news"}` | The channel page sometimes omits the source; the Actor then checks the post's own embed page. `name`/`url` stay `null` if Telegram still does not show them |
| `replyTo` | `{"postId": 557, "url": "https://t.me/durov/557", "text": "Unfair that..."}` | When the post replies to another post |
| `links` | `["https://bbc.in/4C9M4cY"]` | Links in the text and the link preview |
| `hashtags` / `mentions` | `["news"]` / `["designers"]` | Without `#` / `@` |
| `mediaType` | `photo`, `video`, `gif`, `album`, `poll`, `document`, `voice`, `sticker`, `link`, `text`, `unsupported` | |
| `media` | `[{"type": "video", "thumbnailUrl": "https://cdn4.telesco.pe/...", "videoUrl": "...", "duration": "1:15"}]` | Preview images and video URLs as served by the web preview |
| `linkPreview` | `{"siteName": "France 24", "title": "...", "imageUrl": "..."}` | |
| `authorSignature` | `Pavel Durov` | Only for channels that sign posts |

Channel row: `title`, `description`, `verified`, `subscribers` (`9950000`), `subscribersText` (`"9.95M"`), `photos`, `videos`, `files`, `links`, `avatarUrl`, `url`.

### How to use

1. Add channels as usernames (`durov`, `@telegram`) or links (`https://t.me/bbcrussian`, `https://t.me/s/durov`).
2. Set **Max posts per channel**. Posts come newest first, and the Actor follows the channel history page by page (20 posts per page).
3. Optional: a **date range** (`2026-11-01`, an ISO time or `7 days`), **keywords**, and **Only new posts since last run**.
4. Run, then export the dataset to JSON, CSV or Excel.

#### Input examples

Last 200 posts from three channels:

```json
{
  "channels": ["durov", "telegram", "https://t.me/bbcrussian"],
  "maxPostsPerChannel": 200
}
```

Posts from the last 7 days that mention a keyword:

```json
{
  "channels": ["bbcrussian", "meduzalive"],
  "dateFrom": "7 days",
  "keywords": ["Nvidia", "AI"],
  "maxPostsPerChannel": 500
}
```

Monitoring: schedule this every hour. Each run returns only the posts published since the previous run:

```json
{
  "channels": ["durov", "telegram"],
  "onlyNew": true,
  "maxPostsPerChannel": 100,
  "includeChannelInfo": false
}
```

### Use cases

- **Channel monitoring and alerts.** Schedule hourly runs in only-new mode and send new posts to Slack, Google Sheets or a webhook with Apify integrations.
- **Media and PR tracking.** Follow news channels and track mentions of your brand, product or competitors by keyword.
- **Engagement analytics.** Compare views and reactions per post and per channel over time.
- **Research and archiving.** Export a channel's public history to CSV or Excel for analysis.
- **Content curation and AI pipelines.** Feed clean post text, links and hashtags into summarisation, classification or RAG.

### Limits - read before you run

- **Public channels only.** The Actor reads `https://t.me/s/<channel>`, the anonymous web preview that Telegram shows to anyone without logging in. Private channels, groups and chats, bots, user profiles, and channels whose owner disabled the web preview have no such page; they produce an error row and cost nothing.
- **Only what the web preview shows.** Comments, member lists, poll voters and exact reaction or view counts are not on the page. Large numbers are rounded by Telegram (`1.61M`). Some posts (certain media types) show "Please open Telegram to view this post"; they get `mediaType: "unsupported"` and whatever text and counters the page shows.
- **Media links.** You get preview images and the video URLs the page embeds. These CDN links can expire, so download the files soon if you need them. Large videos often have only a thumbnail.
- **Only-new mode** stores the newest post id per channel in a named key-value store in *your* Apify account (`telegram-channel-scraper-state`). It skips posts at or below that id, so it does not see edits to older posts. If more posts were published since the last run than **Max posts per channel** allows, the oldest of them are skipped, so set the limit above what a channel publishes between two runs.
- **Polite speed.** One page (up to 20 posts) at a time with a pause of at least 1.5 seconds, and automatic back-off on HTTP 429. In our tests on Apify, 630 posts from three channels took about 2.5 minutes, so plan roughly 4 minutes per 1,000 posts.

### Pricing

Pay per post: **$0.50 per 1,000 posts** plus a tiny per-run start fee. Channel info rows and error rows are free, and posts skipped by your filters cost nothing. Use **Max posts per channel** and the date range to control the cost.

### Privacy & fair use

The Actor collects only content that channel owners publish to everyone through Telegram's public web preview. It does not log in, does not use the Telegram API, does not bypass any protection and does not collect group members, subscribers' identities or private messages. Respect copyright and the channel owners' rights when you reuse the content, and follow the data protection laws that apply to you.

### FAQ

**Do I need a Telegram account or API key?** No.

**Why does a channel return an error row?** It is not a public channel with a web preview: a group, a bot, a private channel, a typo, or the owner turned the preview off. Open `https://t.me/s/<name>` in a browser: if Telegram redirects you to `https://t.me/<name>`, there is nothing public to scrape.

**Can I get posts older than a date?** Yes. Use `dateTo` together with `maxPostsPerChannel`, or raise **Max pages per channel** for very long histories.

Built and maintained by Alexandr Cheremikin (Koh Samui, Thailand) with an AI assistant. Not affiliated with Telegram.

# Actor input Schema

## `channels` (type: `array`):

Public Telegram channels: usernames (durov, @durov) or links (https://t.me/durov, https://t.me/s/durov). Groups, bots, private channels and channels with the web preview disabled are reported as error rows (free).

## `maxPostsPerChannel` (type: `integer`):

Newest posts first. Stops earlier if the date range or 'only new' mode ends the scan. You pay per post.

## `dateFrom` (type: `string`):

Optional. Only posts published on or after this date: YYYY-MM-DD, an ISO date-time (2026-11-01T00:00:00Z) or relative, e.g. '7 days' or '24 hours'. Scanning stops when older posts are reached.

## `dateTo` (type: `string`):

Optional. Only posts published on or before this date (YYYY-MM-DD includes the whole day), ISO date-time or relative like '1 day'.

## `keywords` (type: `array`):

Optional. Keep only posts whose text or link preview contains at least one of these words or phrases (case-insensitive). Non-matching posts are skipped and not charged.

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

Remembers the newest post id per channel in a named key-value store in your account ('telegram-channel-scraper-state') and on the next run returns only posts newer than that. The first run behaves normally. Schedule the Actor (e.g. hourly) to monitor channels.

## `includeChannelInfo` (type: `boolean`):

Add one free row per channel with title, description, subscribers and photo/video/file/link counts.

## `includeHtml` (type: `boolean`):

Also return the original message HTML (bold, links, custom emoji markup) in the 'html' field, next to the plain 'text'.

## `maxPagesPerChannel` (type: `integer`):

Each page holds up to 20 posts. Limits how far back the scan goes when keyword filters skip most posts.

## `requestDelaySecs` (type: `number`):

Polite pause between page requests to t.me (minimum 1 s). The Actor also backs off automatically on HTTP 429.

## Actor input object example

```json
{
  "channels": [
    "durov",
    "telegram"
  ],
  "maxPostsPerChannel": 20,
  "onlyNew": false,
  "includeChannelInfo": true,
  "includeHtml": false,
  "maxPagesPerChannel": 100,
  "requestDelaySecs": 1.5
}
```

# Actor output Schema

## `posts` (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 = {
    "channels": [
        "durov",
        "telegram"
    ],
    "maxPostsPerChannel": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("cheremikin/telegram-channel-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 = {
    "channels": [
        "durov",
        "telegram",
    ],
    "maxPostsPerChannel": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("cheremikin/telegram-channel-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 '{
  "channels": [
    "durov",
    "telegram"
  ],
  "maxPostsPerChannel": 20
}' |
apify call cheremikin/telegram-channel-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,cheremikin/telegram-channel-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/rxI5Y2X1fRCRnuOic/builds/o0neRbpNiDAcbwuco/openapi.json
