How to make the site a Telegram mini app

← Back

Create a bot with @BotFather, create a section with the app_tg module, enter the bot token in the module settings and click "Connect bot".

  1. In Telegram, open @BotFather → /newbot. Come up with a bot name and address and copy the token.
  2. Create a section, for example /tg, with the app_tg module and access "Everyone".
  3. In "Module settings", paste the "Bot token". If desired, fill in "Section after login", "Bot menu button label" and "Reply to /start and any message to the bot".
  4. Open the section page as an administrator and click "Connect bot". The bot will get an "Open" menu button.
  5. Check the items in the "Settings check" block.

A person opens the bot, clicks "Open" and lands on the site under their own account. On first login the account is created automatically, the name is taken from Telegram. Telegram's "Back" button works like in a browser, and links to other sites open separately. Outside Telegram the site works as usual.

To make the application open via a link like t.me/bot/app and be found in Telegram search, run /newapp in @BotFather and specify the address from the "2. Mini app address" block on the section page.

Top-up with stars is described in a separate article.

If it didn't work

  • The "Connect bot" button gives an error. The site must open over HTTPS, and the token must be copied in full.
  • The bot does not respond, payment is not credited. Click "Check polling". If the site has not received updates from Telegram for a long time, this is a server setting — write to platform support.
  • "Failed to log in". Close the application and open it again from the bot.
Did the article help?

See also

Tips for working with the builder

The "Help" section is made for those who are building a website on "Pervaya Liniya" for the first time. It contains answers to common questions: how to create a website, what to write in the fields, how to edit texts and photos, how to connect your own domain, and how to set up sections. The materials will help you figure things out without contacting support.

The builder is simple: you fill in the fields on the creation page, and then edit the content directly on the finished website. If something does not work or is unclear, check the relevant help item. The instructions are written in plain language and describe every step.

In Help you will find answers to questions:

  • how to come up with a website address and what to do if the name is taken;
  • how to change the title, description, and other texts on the page;
  • how to add products, services, or request forms;
  • how to connect your own domain instead of an address on firstline.com.ua;
  • how to set up sections and modules for your business needs.

If you cannot find the answer you need, use the feedback form — we will help you figure it out. The section is updated so that you can always find current information about working with the builder.