Six Mini Apps: Making Telegram and Mobile Browsers Get Along
How we tested six apps on a Samsung Fold 8 and fixed Telegram Mini App top spacing while keeping browser, tablet and desktop layouts intact.
There is something satisfying about small apps. Each has one understandable job: save a link, track a habit, or finally discover how long that supposedly quick task took. Then you open those same apps in Telegram and discover that the header has its own plans for your screen.
I now have six of these apps. With an AI assistant, I brought them to a home server, tested them on a phone and worked through their appearance as Telegram Mini Apps. One of the most useful discoveries had nothing to do with complicated business logic. It was about a few dozen pixels at the top of the screen.
Six apps for different everyday jobs
- Polka keeps links, materials and notes together for later.
- Tempo brings tasks, notes, a board and time tracking together.
- Podhod holds workout plans and training records.
- Ritm tracks habits, schedules and completion.
- Phrase uses cards to practise words and expressions.
- Metka creates custom QR codes for links and exports PNG or SVG.
They do different jobs, but run on the same devices. A shared layout mistake can therefore reproduce itself remarkably efficiently: fixing one screen means revisiting a whole family of apps.
Why a Telegram Mini App needs top spacing
In a mobile browser, an app opens as an ordinary web page. Inside Telegram, it lives within the messenger's interface. In fullscreen, that environment still has its own controls and safe-area constraints: place content too close to the top edge and the app header can interfere with Telegram's interface.
That is what we accounted for in these apps. On phones inside Telegram, our solution reserves a protective top area of at least 80 pixels. In an ordinary mobile browser, that extra Telegram-specific space is unnecessary, so the normal design spacing stays in place.
There is an important distinction: 80 pixels is a choice made for these particular apps, not a universal value for every Telegram Mini App. Sizes and environments differ. Telegram exposes the device and content safe areas; they should be considered alongside the behaviour of the actual interface. The Telegram Mini Apps documentation describes them as safeAreaInset and contentSafeAreaInset.
A narrow desktop window is not a phone
At first, this looks like a job for one media query: add the space when the screen is narrow. But a Telegram window on a computer can be narrow too. A tablet can display an app in a small window. Suddenly a large blank area appears where nobody asked for it.
We separated two questions: is the app running in Telegram? and is it running on a phone? The extra protection applies when both are true. Desktop and tablet layouts keep their usual spacing, even in a narrow window. The phone protection should also remain when the device is rotated.
The Telegram SDK can still be useful on other devices. Detecting the environment and deciding whether to add top space are separate jobs. That distinction is easy to miss when testing just one window size in developer tools.
How we tested the apps
We opened five apps on a Samsung Fold 8 in Chrome and Telegram, checking workflows, buttons, the keyboard, spacing and rotation where relevant. Later, we applied the same top-spacing logic to Metka, the sixth app. The phone was checked in person; tablets and a narrow desktop window were checked with device profiles. Those profiles are useful, but they do not substitute for every real device and Telegram version.
In Podhod, we also kept the side margins: a workout interface needs to remain comfortable, not merely fit on the screen. Checks covered everyday actions, from creating and changing records to using the timer and cards. After the fix, all six apps were published on the home server.
That does not mean every possible behaviour was tested. Actual reminder delivery and restoring backups, for example, were not checked separately. A fixed header is a good result; it is not proof that every function is flawless.
What I took away
Responsive design is about more than desktop, tablet and phone breakpoints in CSS. The place where an app opens matters too: a browser, Telegram on a phone, or a Telegram window on a computer. Equal width does not make those environments identical.
AI helped us move across several projects and propose and check changes quickly. The decisive part was still a familiar loop: open the app on a real device, see the problem, clarify the desired behaviour and test again. Sometimes the result of a substantial technical effort fits into the empty space above a heading. The trick is making sure that space appears only where it is actually needed.