TradeBot Check
Trading involves a risk of losing money. Nothing on this site is financial advice and past results do not guarantee future results. Risk disclosure
Guide · 2026-11-02

How to get a Telegram alert when a crypto price crosses your level (CoinGecko API)

You do not need to watch charts all day. A small script can check a price every few minutes and message you on Telegram only when it crosses the level you picked. This guide uses the free Demo plan of the CoinGecko API. It is an alert, not a trading signal, and nothing here promises any result.

What you need

  • A Telegram account and a bot token from @BotFather (send /newbot; treat the token like a password).
  • A free CoinGecko API Demo key. The Demo plan has 10,000 call credits per month and 100 calls per minute.
  • Python 3 with the requests library.

Step by step

  1. Get your chat ID. Open your bot, send /start (bots cannot message you first) and read the chat ID from the getUpdates response of the Telegram Bot API.
  2. Ask for the price. The /simple/price endpoint returns prices for the coins and currencies you name. For the Demo plan, the base URL is https://api.coingecko.com/api/v3/ and the key goes in the x-cg-demo-api-key header. A request with ids=bitcoin and vs_currencies=usd returns a small JSON such as {"bitcoin": {"usd": 76975}}.
  3. Compare with your level. In Python, read the number and check it against your threshold, for example if price >= 80000.
  4. Send the message. Post to https://api.telegram.org/bot<token>/sendMessage with your chat_id and a text such as "Bitcoin is above your level".
  5. Avoid repeats. Keep a small flag (a variable or a file) so you are alerted once per crossing, not at every check.
  6. Schedule it with cron or your task scheduler.

Mind the monthly credits

Checking every minute means about 43,200 calls a month, far above the 10,000 of the Demo plan. Check every 5 minutes instead (about 8,600 calls) or ask for several coins in one request, since one call can include many ids. Check the official pricing page for current limits.

Other ways to do it

Good to know

Prices from a free API can lag by a short time, so use this for awareness, not for split-second decisions. Any trading idea should be backtested with fees and tested in simulation first, and with risk limits you set yourself. The Demo key must stay out of public repositories.

See more ideas

Browse the use cases or try the live demo. Custom bots are coming soon: tell me when it opens.

Before you start

What does CoinGecko API cost and what licence does it use?

Free Demo plan; paid plans from $35/mo (Basic). Licence: Commercial service. Prices change, so check the official website before you decide.

What should I know before using CoinGecko API?

10,000 calls a month run out fast if you poll every minute (about 43,000 a month).

Tools in this guide

  • CoinGecko API: Crypto data API (prices, market cap, history) with a free Demo plan.

Want a bot like this when custom bots open? Get notified · more bot ideas

Coming soon

Coming soon: custom bots

We are preparing a service to code, backtest and automate trading and statistics bots to your own rules. It is not available yet: follow our Telegram channel to know when it opens.

Tools mentioned in this guide

More guides