Skip to content

[web] iOS Safari auto-zooms the page to 1.45x when a TextField is tapped with semantics enabled #192327

Closed

Description

@flutter-zl

Steps to reproduce

On iOS, with semantics enabled, tapping a TextField zooms the whole page to about 1.45x and leaves it there. The user has to pinch back out manually, and typing continues at the zoomed scale.

The cause is that Flutter's semantic <input> never sets a font-size, so it inherits the browser's default, which is 11px on iOS. iOS Safari auto-zooms whenever it focuses an input whose font size is under 16px.

This is WebKit-only behavior, and it became reachable only after #190486. Before that fix the semantic input was about one viewport off-screen and could never be focused, so it never triggered a zoom.

Steps to reproduce

  1. Create a Flutter web app that calls SemanticsBinding.instance.ensureSemantics(). A real screen reader enables semantics on its own; this forces it for a deterministic repro.
  2. Add a TextField (see the code sample).
  3. flutter build web, deploy, and open on a physical iPhone in Safari.
  4. Tap the text field.

Demo, no fix applied: https://flutter-demo-50-before.web.app

Related issues

Expected results

Tapping the field focuses it and opens the keyboard without changing the page zoom.

Actual results

The page zooms to about 1.45x and stays zoomed. Because iOS only auto-zooms when the focused input is effectively under 16px at the current scale, re-tapping does nothing further until the user pinches back to visualViewport.scale = 1.0, at which point the next tap zooms again.

Code sample

https://flutter-demo-50-before.web.app

Screenshots or Video

Screenshots / Video demonstration

[Upload media here]

Logs

Logs
[Paste your logs here]

Flutter Doctor output

Flutter 3.48.0-1.0.pre-635 • channel [user-branch] • [email protected]:flutter/flutter.git
Framework • revision 2d39b7da70 • 2026-09-04
Engine • hash e9027840f8346ec5cec796b494f03097cc2edfa1 (revision 04d081abd8) • 2026-09-04
Tools • Dart 3.14.0 (build 3.14.0-194.0.dev) • DevTools 2.61.0-dev.0

Activity

  1. self-assigned this
    on Sep 5, 2026
  2. added
    P1High-priority issues at the top of the work list
    triaged-webTriaged by Web platform team
    on Sep 5, 2026
  3. flutter-triage-bot commented on Sep 5, 2026

    @flutter-triage-bot

    The triaged-web label is irrelevant if there is no team-web label or fyi-web label.

  4. added a commit that references this issue on Sep 10, 2026
    0414680
  5. github-actions commented on Sep 24, 2026

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  6. locked as resolved and limited conversation to collaborators on Sep 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P1High-priority issues at the top of the work listteam-webOwned by Web platform teamtriaged-webTriaged by Web platform team

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions