<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>230225</bug_id>
          
          <creation_ts>2021-09-13 11:43:11 -0700</creation_ts>
          <short_desc>Implement the VirtualKeyboard API</short_desc>
          <delta_ts>2026-04-15 12:01:13 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>New Bugs</component>
          <version>Other</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Bramus">bramus</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>03_placid_daft</cc>
    
    <cc>alex_breen</cc>
    
    <cc>apolostudioapps</cc>
    
    <cc>brian</cc>
    
    <cc>cyb.ai.815</cc>
    
    <cc>dbates</cc>
    
    <cc>dvpdiner2</cc>
    
    <cc>fred</cc>
    
    <cc>hendrex.jakai</cc>
    
    <cc>ik</cc>
    
    <cc>jesse.t.morton</cc>
    
    <cc>john.crim</cc>
    
    <cc>josh</cc>
    
    <cc>kevin_neal</cc>
    
    <cc>mahmoodsagharjooghi</cc>
    
    <cc>matan.hershberg</cc>
    
    <cc>matt</cc>
    
    <cc>me</cc>
    
    <cc>megan_gardner</cc>
    
    <cc>pablo.osorno.94</cc>
    
    <cc>schneider</cc>
    
    <cc>sviatsv</cc>
    
    <cc>the.bull</cc>
    
    <cc>Thenly123q</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>webkit</cc>
    
    <cc>wenson_hsieh</cc>
    
    <cc>woodlxf00</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1793028</commentid>
    <comment_count>0</comment_count>
    <who name="Bramus">bramus</who>
    <bug_when>2021-09-13 11:43:11 -0700</bug_when>
    <thetext>&gt; The VirtualKeyboard API provides authors with greater control over the visibility of the virtual keyboard (VK), and greater ability to adapt the layout of web pages when VK visibility changes.

Relevant Links:

- Explainer: https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/VirtualKeyboardAPI/explainer.md
- Spec: https://www.w3.org/TR/virtual-keyboard/</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1793030</commentid>
    <comment_count>1</comment_count>
    <who name="Bramus">bramus</who>
    <bug_when>2021-09-13 11:45:32 -0700</bug_when>
    <thetext>Other Browsers/Engines:

- Chromium: https://www.chromestatus.com/feature/5680057076940800 (Shipping with Chromium 94)
- Gecko/Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=1730568</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1793730</commentid>
    <comment_count>2</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2021-09-15 09:40:27 -0700</bug_when>
    <thetext>&lt;rdar://problem/83154723&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1793731</commentid>
    <comment_count>3</comment_count>
    <who name="Kevin Neal">kevin_neal</who>
    <bug_when>2021-09-15 09:41:30 -0700</bug_when>
    <thetext>Thank you for filing. The appropriate engineers have been notified.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1923155</commentid>
    <comment_count>4</comment_count>
    <who name="N">hendrex.jakai</who>
    <bug_when>2023-01-05 08:40:55 -0800</bug_when>
    <thetext>Hello,

Any update on this?

It&apos;s very hard (if possible at all) to control whether the Keyboard hides the bottom contents of the screen, which is different from the behavior of the other browsers on Android.

Chrome v108 allows to control this via viewport meta - https://developer.chrome.com/blog/viewport-resize-behavior/

which gives more flexibility to devs.

Would be nice to see Safari implementing any kind of flexibility, as at the moment we have none.

Thanks</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1976172</commentid>
    <comment_count>5</comment_count>
    <who name="Alex 23">alex_breen</who>
    <bug_when>2023-09-07 10:05:51 -0700</bug_when>
    <thetext>Adding a vote that this is an important iOS Safari enhancement for many web developers, and working well on Chrome/Android.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1976517</commentid>
    <comment_count>6</comment_count>
    <who name="John Crim">john.crim</who>
    <bug_when>2023-09-08 14:16:48 -0700</bug_when>
    <thetext>I would love to see the VirtualKeyboard API implemented in Safari/iOS browsers, but at a minimum we need a way to control the viewport when the On Screen keyboard appears. 

The Safari viewport is always full-screen, even when the On Screen keyboard displays, as described here:
https://developer.chrome.com/blog/viewport-resize-behavior/ 

Chrome/Android supports `interactive-widget=resizes-content` in the meta viewport tag, which has the desired behavior of shrinking the viewport to what is visible.

The Safari behavior means that any dialog that is shown has the full screen height, and can&apos;t be constrained to the part of the screen that is visible above the keyboard - the area behind the keyboard always exists, even if it&apos;s not needed.

Imagine a short dialog - on Safari you can still scroll to the bottom of the full screen height, and there is no way to reduce the scroll height below a full screen. 

On Chrome/Android with `viewport interactive-widget=resizes-content`, the short dialog is all that is displayed. If the dialog is taller than the visual viewport, it can be scrolled to the bottom, but there is no additional space below the page content. I can provide a video of this issue if my description is lacking.

With some hacks, you can currently detect when the On Screen Keyboard is shown (`visualViewport.resize` event, plus input or textarea is focused). We currently don&apos;t use the VirtualKeyboard API to detect this even though it would be a better way, b/c it wouldn&apos;t work on Safari. 

Even with On Screen Keyboard detection solved, there is no way to control the max viewport height on Safari.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2026426</commentid>
    <comment_count>7</comment_count>
    <who name="Fred Rivett">fred</who>
    <bug_when>2024-04-05 17:43:44 -0700</bug_when>
    <thetext>Totally appreciate there&apos;s always more in the backlog than can be done, just adding my vote in for this one to be prioritised.

I&apos;ve just spent 3 days banging my head against this desperately trying to find a way to simply put a div at the bottom of the screen regardless of whether the virtual keyboard is open. In the end we&apos;ve implemented a very hacky solution that *seems* to work, and I can rest a little easier this weekend.

I feel like it&apos;s a relatively common requirement and as such many devs will be losing time (and sleep) over this, so it would be great if safari (&amp; FF) could bridge the gap as the only two major browsers holding developers back from using this feature.

Thanks folks,
Fred.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2050509</commentid>
    <comment_count>8</comment_count>
    <who name="Mahmood Sagharjooghi">mahmoodsagharjooghi</who>
    <bug_when>2024-08-03 14:57:03 -0700</bug_when>
    <thetext>After a day of trying to position an input element to the bottom of the screen regardless of virtual keyboard being open or not, I find myself in this bug report. Please prioritize this. It not working on IOS is a truly a headage for many.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2050510</commentid>
    <comment_count>9</comment_count>
    <who name="Mahmood Sagharjooghi">mahmoodsagharjooghi</who>
    <bug_when>2024-08-03 14:58:15 -0700</bug_when>
    <thetext>(In reply to Fred Rivett from comment #7)
&gt; Totally appreciate there&apos;s always more in the backlog than can be done, just
&gt; adding my vote in for this one to be prioritised.
&gt; 
&gt; I&apos;ve just spent 3 days banging my head against this desperately trying to
&gt; find a way to simply put a div at the bottom of the screen regardless of
&gt; whether the virtual keyboard is open. In the end we&apos;ve implemented a very
&gt; hacky solution that *seems* to work, and I can rest a little easier this
&gt; weekend.
&gt; 
&gt; I feel like it&apos;s a relatively common requirement and as such many devs will
&gt; be losing time (and sleep) over this, so it would be great if safari (&amp; FF)
&gt; could bridge the gap as the only two major browsers holding developers back
&gt; from using this feature.
&gt; 
&gt; Thanks folks,
&gt; Fred.

Hi Fred!
Can you share the solution? It&apos;ll be much appreciated 🙏</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2089627</commentid>
    <comment_count>10</comment_count>
    <who name="">brian</who>
    <bug_when>2025-01-24 13:25:48 -0800</bug_when>
    <thetext>Id like to throw my vote in to prioritize this as well for ios. (works well on android chrome) 

navigator.virtualKeyboard is desperately needed to help us developers meet user expectations. 

the visualViewport or measuring the client in any current manner is completely inadequate at detecting the visibity of the keyboard,  as the keyboard visibity does not necesasrily trigger the changes to the viewport siize.  Take for example the case where an input exists at the top of the screen with enough padding to allow the keyboard to open.  in that case there is no way that i can find to understand if the keyboard has been shown or hidden.  

I agree in general with other comments that we should be able to have more control over the visualViewport and how it responds to the keyboard,but i know fromo my own development that simply reliable detcting the keyboard would be a huge benefit in it&apos;s own right.  

Thanks,
Brian</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2104658</commentid>
    <comment_count>11</comment_count>
    <who name="">jesse.t.morton</who>
    <bug_when>2025-03-20 08:59:01 -0700</bug_when>
    <thetext>I also would love to see development of this. 

For a potential workaround in the meantime, see https://stackoverflow.com/a/71547560/4185989 for VisualViewport use (ref https://developer.mozilla.org/en-US/docs/Web/API/VisualViewport)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2106097</commentid>
    <comment_count>12</comment_count>
    <who name="Offickind1939">Thenly123q</who>
    <bug_when>2025-03-26 02:10:54 -0700</bug_when>
    <thetext>Thank you for your submission. The relevant engineers have been informed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2106099</commentid>
    <comment_count>13</comment_count>
    <who name="Offickind1939">Thenly123q</who>
    <bug_when>2025-03-26 02:11:36 -0700</bug_when>
    <thetext>@[url=https://fallguysonline.com]fall guys online[/url]</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2107262</commentid>
    <comment_count>14</comment_count>
    <who name="">ik</who>
    <bug_when>2025-03-30 01:08:09 -0700</bug_when>
    <thetext>Friendly ping, what&apos;s the WK-team&apos;s position on this? Thanks!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2166228</commentid>
    <comment_count>15</comment_count>
    <who name="">matt</who>
    <bug_when>2025-12-16 07:34:39 -0800</bug_when>
    <thetext>This is very much needed to create chat ui&apos;s, there are a considerable number of hacks to get an OK experience on iOS whereas Chrome just works</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2166621</commentid>
    <comment_count>16</comment_count>
    <who name="">me</who>
    <bug_when>2025-12-17 08:23:50 -0800</bug_when>
    <thetext>Ping as well, extremely needed for rich chat applications!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2200751</commentid>
    <comment_count>17</comment_count>
    <who name="Apolo">apolostudioapps</who>
    <bug_when>2026-04-15 12:01:13 -0700</bug_when>
    <thetext>Gentle bump, really important for Canvas-based frameworks like https://github.com/JetBrains/compose-multiplatform (it simplifies and enables the framework to handle all this work instead which can reduce weird workarounds and difficult to reason code)</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>