Scrape data from Telegram

Public Telegram channels broadcast a lot worth tracking, posts, links, view counts, dates. A bot can read them off the web version into a sheet, so monitoring a channel does not mean scrolling it by hand. This is for public channels, not for harvesting people. There are three ways to start, with no code, with code, or with a Claude skill.

What I mean by scraping Telegram


Scraping Telegram means a bot reads the posts from a public channel into a sheet. The message text, any links, the view count, the date. Point it at a public channel's web page and it gathers the recent posts, so watching a channel for mentions or tracking what it publishes becomes a row in a spreadsheet instead of an afternoon of scrolling.

Public channels are public, member lists are not


There is a clear line on Telegram, and it matters. Public channels are broadcasts, anyone can open them on the web and read the posts, so reading them into a sheet is fair. Group member lists, private chats, and people's contact details are a different thing entirely. Harvesting members to message or add elsewhere is how Telegram spam works, and it is not something to build.

So stay on the broadcast side. Telegram also has an official API if you want a sturdier route into your own channels and bots. The browser is for the simple case, reading the public posts of a public channel for monitoring or research, at a reasonable pace. Public posts, yes. People, no.

Who this is for


This is for the person monitoring public Telegram channels, not the people in them. A researcher tracking what a channel posts, a marketer watching for mentions, an analyst gathering announcements over time. Public broadcasts, into a sheet. If you are looking to harvest members or scrape private chats, this is not the tool. No-coders and coders both, since you can build it without code and drop into code when you want.

How I'd approach it


Use the web preview of a public channel as your source. Point the bot at it, read the recent posts, the text, the links, the view counts, and write them to a sheet. To watch over time, run it on a schedule and keep only what is new. Stay on public channels, take the posts not the people, and keep the pace steady.

Public channel, posts only, on a schedule. I would lay out the first draft with Build with description.

Scrape Telegram from a description


Describe the channel and fields in plain words in the Chrome extension and it builds the steps for you. Give it a few short lines, check what it made, and run it. Explore no-code.

To the right is an example. Describe the channel and the fields you want, and the AI lays out the steps.

Chrome extension
Describe your automation

Instructions

  • Open the public channel's web page34 / 500
  • Scroll to load the recent posts31 / 500
  • Scrape the post text and any links34 / 500
  • Grab the view count and date28 / 500
  • Write them to a Google Sheet28 / 500

Scrape Telegram in code


Build with code. If you would rather script it yourself, this is the path. Explore code

Connect Playwright (or Puppeteer) to our cloud Chromium and write the same scripts you'd run locally, without managing the browser.

Code tool
Code example
import { chromium } from "playwright";

const browser = await chromium.connectOverCDP(
  `wss://cdp-lb.axiom.ai/?token=${process.env.AXIOM_API_KEY}`
);

try {
  const context = browser.contexts()[0];
  const page = context.pages()[0] ?? await context.newPage();

  // The public web preview of a public channel
  await page.goto("https://t.me/s/somechannel");
  await page.waitForSelector(".tgme_widget_message");

  // Read the recent public posts
  const posts = await page.$$eval(".tgme_widget_message", els =>
    els.map(el => ({
      text: el.querySelector(".tgme_widget_message_text")?.textContent.trim(),
      date: el.querySelector("time")?.getAttribute("datetime"),
      views: el.querySelector(".tgme_widget_message_views")?.textContent.trim(),
    }))
  );

  console.log(posts); // write these to your sheet
} finally {
  await browser.close();
}

Build with a Claude skill

Build no-code or code bots with a skill.

Add the Claude skill and describe the public channel you want to watch. It builds the bot for you, no-code or code, reading posts into a sheet.

Claude building a Telegram channel scraper from a description

What can you scrape?


Public channel posts, into a sheet. A couple of lines to stay on the right side of.

Works well

  • Post text and links from a public channel
  • View counts and dates
  • Watching a channel over time
  • Gathering announcements into a sheet
  • Running it on a schedule

Harder

  • Channels that need you to open the app
  • Media posts with little text
  • Very long histories in one run

Don't try

  • Harvesting group members or contacts
  • Scraping private chats
  • Anything against Telegram's terms

What I'd watch out for


Telegram splits sharply into public and private, so the line is what matters most. Here is what I would watch for.

Posts, not people

Reading a public channel's posts is fine. Gathering its members, their usernames, or their contact details is not, and it is the start of spam. Take what the channel broadcasts, never who is in it.

Use the public web preview

A public channel has a web page at the t.me/s address that loads its posts without the app. Point the scraper there, and you are reading what is already open to everyone.

Consider the API for your own channels

If you run the channel, Telegram's official API is a sturdier route than scraping the page. Use the browser for reading public channels, the API for your own.

Keep the pace steady

There is no need to rush a public page. Space out the requests, pick what you read with the selector tool, and take long histories in chunks.

"Axiom has saved me countless hours. The automation possibilities are endless."

Robert Taylor

"The best browser automation tool I've used. The AI features are game-changing for complex workflows."

Sarah Johnson

"I was skeptical about no-code automation, but Axiom proved me wrong. It's incredibly powerful."

David Wilson

"The support team is amazing, and the product just keeps getting better. Worth every penny."

Emma Davis

"The visual builder is a dream come true. No more writing complex scripts!"

Lisa Anderson

"Finally, a tool that makes browser automation accessible without compromising on power. Highly recommended!"

Michael Chen

"Axiom has completely transformed how I handle browser automation. The no-code interface is intuitive and powerful."

John Smith

Fast to build. Easy to run and scale. Outstanding support.

Start for free. No credit card required.