Integrations · Beginner

How to set up a proxy in Telegram: SOCKS5 on every device

Every Telegram app has a proxy setting built in. Point it at a SOCKS5 proxy and the app reaches Telegram's servers through the exit you choose, without a VPN on the rest of the device.

3 min read 8 sections Updated Published

What you need#

  • A SOCKS5 server and port, a username and a password. Telegram has no field for IP whitelisting, so use credentials.
  • A sticky session, so the exit does not change while the app holds its connection open. On HodlProxy, add -sid- and -ttl-24h to the username.
  • An exit in a country where Telegram works normally, ideally close to you for lower latency.
Server
res.hodlproxy.com (rotating pool) or your dedicated IP
Port
9001 on the gateways, 8001 on dedicated addresses
Username
USER-cc-nl-sid-tg1-ttl-24h (country NL, session tg1, held 24 hours)
Password
PASS, from your dashboard

Android#

  1. Open Telegram, tap the menu, then Settings → Data and Storage → Proxy.
  2. Tap Add Proxy and choose SOCKS5.
  3. Fill in server, port, username and password, then save.
  4. Switch Use Proxy on. The shield icon in the chat list turns blue once connected.

iPhone and iPad#

  1. Open Settings → Data and Storage → Proxy.
  2. Tap Add Proxy, choose SOCKS5 and enter server, port, username and password.
  3. Tap Done, then select the proxy in the list to activate it.

Windows, macOS and Linux#

In Telegram Desktop, open Settings → Advanced → Connection type, choose Use custom proxy, then SOCKS5, and enter the same four values. In the native macOS app the setting sits under Settings → Data and Storage → Proxy, as on the iPhone.

Telegram opens proxy links directly: anyone who taps one gets the setting pre-filled. Keep links with credentials private, since anyone holding them can spend your traffic.

Telegram SOCKS5 link
https://t.me/socks?server=res.hodlproxy.com&port=9001&user=USER-cc-nl-sid-tg1-ttl-24h&pass=PASS

SOCKS5 or MTProto?#

SOCKS5MTProto proxy
ProtocolA standard proxy protocolTelegram's own protocol with a secret key
Works forTelegram and any other appTelegram only
AuthenticationUsername and passwordA shared secret
Typical sourcePaid providers, your own serverVolunteers and sponsors, often with a promoted channel

HodlProxy provides SOCKS5 and HTTP(S), not MTProto. A paid SOCKS5 exit is private to your account, which public MTProto servers are not.

Keep the connection stable#

  • Use a long sticky session (-ttl-24h): Telegram keeps a connection open, and a changing exit forces reconnects.
  • For an always-on proxy, a dedicated ISP or datacenter address never changes and carries unlimited or pooled traffic, which suits media-heavy chats.
  • Leave Use proxy for calls off: voice and video calls need UDP, and HodlProxy relays TCP only, so calls connect directly instead.
  • An idle connection is closed after 60 seconds without traffic; Telegram reconnects on its own.

Troubleshooting#

SymptomLikely causeFix
Stuck on "Connecting…"Wrong port or protocolSOCKS5 on 9001 (gateways) or 8001 (dedicated), not 9000/8000
Proxy unavailableCredentials rejectedRe-copy username and password; check for spaces
Reconnects every few minutesNo sticky sessionAdd -sid-NAME-ttl-24h to the username
Media loads slowlyDistant exitPick a country closer to you, or a dedicated ISP address

Questions people ask#

Is it legal to use a proxy with Telegram?

Telegram supports proxies natively in every app, and using a proxy is legal in most countries. You remain responsible for complying with the laws that apply where you are.

Does a proxy hide my phone number?

No. A proxy changes the IP address Telegram's servers see; your account, phone number and contacts are unchanged. Privacy settings inside Telegram control who sees your number.

Can I use one proxy on several devices?

Yes. The same credentials work on every device, and HodlProxy does not limit concurrent connections. Use a different session ID per device if each should keep its own exit.

Which HodlProxy network is best for Telegram?

A dedicated ISP or datacenter address for an always-on setup with lots of media, since traffic is unlimited or pooled; a sticky residential session if you only need the app occasionally.

Ready when you are

Run it for real.

Create an account, top up $20 and paste the endpoint from this guide into your tool. Traffic you buy never expires.