TGViewer
teleLakel teleLakel @telelakel · 17.7K subscribers
Post #1186 11K
💻 Telegram is rewriting its MTProto network stack in Rust after more than 10 years

In the Beta versions of Telegram for iOS and macOS, a new MTProtoRustEngine has appeared — a network engine implementation in Rust that is gradually replacing MTProtoKit.

MTProtoKit is Telegram's old network stack for Apple platforms. It has been developed for more than 10 years and is built with C, Objective-C, and C++. Public references to MtProtoKit for iOS and OS X date back to 2014.


Telegram is now gradually moving this part of its Apple clients to Rust. The new engine already has its own network sessions, request handling, buffers, data center communication, and a separate layer for interaction between Rust and Swift. The old code isn't going anywhere yet. Both engines are present in the client at the same time — MTProtoKit and Rust. Switching between them is handled by SwitchingNetworkEngine: if the new engine can't continue working, unfinished requests can be passed back to the old one.

There are also conditions under which the Rust engine isn't used, including Web Proxy, custom data center addresses, and certain app extensions. In these cases, Telegram continues using the old MTProtoKit.

Telegram has also added the mtproto_engine_rust_disabled configuration, which allows the server to forcibly disable the Rust engine. Together with the fallback to MTProtoKit, this allows Telegram to gradually move clients to the new stack and return to the old implementation when needed — without releasing a new client version.

@telelakel | #new_tgbeta
More from @telelakel
  1. Oct 9, 2026🙄 Spammers have started sending spam transactions to Telegram's new Gram Wallet users. Yo…
  2. Oct 9, 2026💎 The new built-in Gram Wallet on Android in action. The video shows its interface and fe…
  3. Oct 8, 2026🤖 Telegram is adding support for suffixes in bot usernames. New methods for managing seco…
  4. Oct 8, 2026💬 In Telegram Beta for macOS 12.10.283300, an experimental «HTMLBubbles» subsystem has ap…
  5. Oct 8, 2026Note. AppConfig has not been updated on the production server yet. Users still don't have…
  6. Oct 8, 2026🤖 Telegram updated stable version for iOS and Android to v13.0.0 — Gram Wallet. Telegram'…
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →