Typing Indicator in Mobile App Chat

NOVASOLUTIONS.TECHNOLOGY is engaged in the development, support and maintenance of iOS, Android, PWA mobile applications. We have extensive experience and expertise in publishing mobile applications in popular markets like Google Play, App Store, Amazon, AppGallery and others.
Development and support of all types of mobile applications:
Information and entertainment mobile applications
News apps, games, reference guides, online catalogs, weather apps, fitness and health apps, travel apps, educational apps, social networks and messengers, quizzes, blogs and podcasts, forums, aggregators
E-commerce mobile applications
Online stores, B2B apps, marketplaces, online exchanges, cashback services, exchanges, dropshipping platforms, loyalty programs, food and goods delivery, payment systems.
Business process management mobile applications
CRM systems, ERP systems, project management, sales team tools, financial management, production management, logistics and delivery management, HR management, data monitoring systems
Electronic services mobile applications
Classified ads platforms, online schools, online cinemas, electronic service platforms, cashback platforms, video hosting, thematic portals, online booking and scheduling platforms, online trading platforms

These are just some of the types of mobile applications we work with, and each of them may have its own specific features and functionality, tailored to the specific needs and goals of the client.

Showing 1 of 1 servicesAll 1735 services
Typing Indicator in Mobile App Chat
Simple
~1 business day
FAQ
Our competencies:
Development stages
Latest works
  • image_mobile-applications_feedme_467_0.webp
    Development of a mobile application for FEEDME
    756
  • image_mobile-applications_xoomer_471_0.webp
    Development of a mobile application for XOOMER
    624
  • image_mobile-applications_rhl_428_0.webp
    Development of a mobile application for RHL
    1054
  • image_mobile-applications_zippy_411_0.webp
    Development of a mobile application for ZIPPY
    947
  • image_mobile-applications_affhome_429_0.webp
    Development of a mobile application for Affhome
    862
  • image_mobile-applications_flavors_409_0.webp
    Development of a mobile application for the FLAVORS company
    445

Implementation of Typing Indicator in Mobile Chat

Three dots in a messenger — one of those small UX elements users notice only when it's missing. Implementation seems trivial until you hit debounce, consistency across devices, and proper behavior on unstable connections.

How the Mechanics Works in Practice

Basic scheme: client sends typing_start event on each key press, peer sees indicator, after N seconds without new events indicator fades. On paper — simple. In practice — three typical problems.

Event flood. Without debounce, each onTextChanged (Android) or textDidChange (iOS) generates network call. User typing a message in 5 seconds creates 20–30 unnecessary requests. Correct solution — send typing_start only if more than 2–3 seconds passed since previous send, and typing_stop with delay ~4 seconds after last character.

On Android this is implemented via Handler.postDelayed or debounce operator in RxJava/Kotlin Flow:

private var typingJob: Job? = null

fun onTextChanged(text: String) {
    if (text.isEmpty()) {
        sendTypingStop()
        return
    }
    typingJob?.cancel()
    typingJob = viewModelScope.launch {
        delay(TYPING_THROTTLE_MS) // 3000ms
        sendTypingStart()
    }
}

On iOS similar logic via Timer.scheduledTimer or Combine:

private var typingCancellable: AnyCancellable?

func textDidChange(_ text: String) {
    typingCancellable?.cancel()
    typingCancellable = Just(text)
        .delay(for: .seconds(3), scheduler: RunLoop.main)
        .sink { [weak self] _ in self?.sendTypingStart() }
}

Transport layer. Typing indicator is ephemeral state that doesn't require delivery guarantees. Therefore REST/HTTP is overkill here. Optimal choice — WebSocket or Firebase Realtime Database. Via WebSocket send lightweight JSON packet {"type":"typing","chat_id":"...","user_id":"..."}. Via Firebase — entry in ephemeral node /typing/{chatId}/{userId} with TTL via onDisconnect().removeValue(). Second variant automatically cleans state on disconnection — critical.

Display on receiver. After receiving event need to show indicator and start cleanup timer (~5 seconds). If new event arrives within — reset timer. Animation of three dots: on iOS — custom CABasicAnimation or Lottie, on Android — AnimationDrawable or Lottie animation via LottieAnimationView. Flutter solves this via AnimatedOpacity + Timer.

What We Do

Analyze existing chat transport layer (WebSocket, Firebase, XMPP — all have their nuances), add debounce on client, implement display with proper animation and state auto-cleanup. If no chat exists yet — design from scratch for required stack.

Timeline: 1–3 days depending on current chat architecture complexity.