Views: 10 visits
telegram channel viewer PHP script preview on website

If you’re looking for a Telegram channel viewer PHP script that doesn’t require any API access or bot token, this tool is exactly what you need. It fetches and displays the latest posts from any public Telegram channel by directly parsing the t.me/s/CHANNEL page. With full caching and optional static HTML rendering, this script is ideal for restricted environments like Iran.


✅ What Does This Script Do?

The “Telegram Channel Viewer” is a two-part system designed to bypass access restrictions and present Telegram content seamlessly:

✔ On a foreign server (outside Iran, with Telegram access):

  • Fetches the latest posts from a public channel
  • Saves them in cache.json and static.html
  • Renders clean HTML output using modern Persian fonts

✔ On a local server (inside Iran):

  • Loads cached HTML content from the foreign server
  • Displays posts instantly with no need for Telegram access
  • Includes a reset button to clean up the cache and keep performance high

⚙ Key Features

  • No Telegram API or bot token required
  • Fully PHP-based with zero external dependencies
  • Static frontend – perfect for shared hosting
  • Caches the latest 100 posts
  • Responsive design and RTL support (Vazir / IranSans fonts)
  • Remote reset cache feature from local host

🔧 How to Set It Up

📁 Step 1: Upload to Foreign Host

  • Files: fetch.php, update-cache.php, render.php, reset-cache.php
  • Change $channel in update-cache.php to your desired Telegram username
  • Set up a cron job to run update-cache.php every 10 minutes

📁 Step 2: Upload to Local (Iranian) Host

  • Files: index.php, proxy.php, reset.php
  • In proxy.php and reset.php, point the URLs to your foreign server

📷 What Does It Look Like?

The script generates beautiful blocks for each Telegram post with inline images and text, optimized for mobile and desktop. It works smoothly even on slower connections.


📆 Why Use This Script?

  • No need for Telegram API or bot token
  • Fully open-source and editable
  • Lightweight and fast (ideal for shared hosting)
  • Caching system included
  • Static HTML rendering supported

📅 Use Cases

  • Display Telegram news channels on your website
  • Embed channel updates into WordPress or any CMS
  • Bypass Telegram filters for Iranian audiences
  • Use in news aggregators or monitoring dashboards

🧰 How It Works

This script fetches content directly from:

https://t.me/s/YOUR_CHANNEL_USERNAME

It uses PHP cURL and DOM parsing to extract posts, saves them in JSON, and optionally generates a static HTML file.


📦 Download the Script

You can download the full package here, which includes all files for both foreign and local host configurations with clearly separated folders.

🚀 Ready to implement it on your website?
Download the full Telegram Channel Viewer Script from P30Script, including all required files for both foreign and local hosting setups. It’s a lightweight, API-free solution perfect for embedding Telegram content even in restricted regions.


🛡️ Performance Tips

  • Set cache.json and static.html file permissions to 666
  • Run reset.php occasionally to retain only the latest 100 posts
  • Use an image CDN if you want to serve cached media faster

📓 Final Thoughts

If you’re searching for a reliable, API-free, fast solution to show Telegram channel content on your website — even under access restrictions — this script offers a practical, elegant answer.

👉 Explore the product and download the Telegram Channel Viewer


🌟 Developed by P30Script – Smart Tools for Smart Webmasters

Read more