Web-Facing Change PSA: Speculation rules: mobile "moderate" eagerness improvements

214 views
Skip to first unread message

Domenic Denicola

unread,
Jun 23, 2025, 4:55:11 AMJun 23
to blink-dev, Hiroki Nakagawa

Contact emails

nhi...@chromium.org

Specification

https://wicg.github.io/nav-speculation/speculation-rules.html#:~:text=early%20as%20possible.-,%22moderate%22,balance%20between%20%22eager%22%20and%20%22conservative%22.,-%22conservative%22

Summary

On mobile, "moderate" eagerness speculation rules prefetches and prerenders now trigger when a link enters the viewport and passes other conditions that indicate that it's more likely to be clicked. The previous behavior, of waiting until pointerdown, was the same as "conservative" eagerness. This new behavior is more useful as it better reflects author intent to be more eager than the "conservative" setting. More detail on this and other upcoming improvements to speculation rules eagerness are available at https://docs.google.com/document/d/1YPbtUPfZIDElzBZNx8IQMzRFvy8oauLG_i1XIr6jgTs/edit?usp=sharing.



Blink component

Internals>Preload

Risks



Interoperability and Compatibility

The exact definitions of eagerness levels are left vague in the specification. ("User agents should enact the candidate if user behavior suggests the user may navigate to this URL in the near future. For instance, the user might have scrolled a link into the viewport and moved the cursor over it for some time.") This change is in line with those suggestions. Due to speculation rules' nature as a progressive enhancement, it is very hard to depend on the exact heuristic, so varying across browser engines, platforms, and browser versions should not pose significant interoperability or compatibility risks. As evidence, the heuristic has varied across mobile and desktop ever since launch, and this has not caused such problems.



Gecko: Neutral (https://github.com/mozilla/standards-positions/issues/620#issuecomment-2546739520) We have not asked Firefox for their thoughts on this specific change. They are positive on and implementing prefetching, and will likely make their own choices for how to implement each eagerness level.

WebKit: No signal (https://github.com/WebKit/standards-positions/issues/54) We've not asked Safari for their thoughts on this specific change. They have recently indicated a tentative positive position towards conservative-eagerness prefetching.

Web developers: Positive We've seen several developers re-create this viewport-based technique using JavaScript to manually insert and remove speculation rules, e.g. in the Quicklink library.

Other signals:

WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?

None



Debuggability

We have unfortunately not yet made this feature work in DevTools mobile emulation mode. That work is tracked in https://issues.chromium.org/issues/420724833 and will be worked on as a follow up.


Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?

No

This is only applicable to Android, and speculation rules are not yet supported on Android WebView.


Is this feature fully tested by web-platform-tests?

No

Because the specification intentionally allows user agent flexibility, web platform tests do not capture any specific heuristic here.


Flag name on about://flags

None

Finch feature name

PreloadingViewportHeuristics

Rollout plan

(RARE) Experiment users ramp up over time

Tracking bug

https://issues.chromium.org/issues/372053392

Estimated milestones

Shipping on Android138

Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5079361929347072?gate=5206542386987008

This intent message was generated by Chrome Platform Status.

Yoav Weiss (@Shopify)

unread,
Jun 23, 2025, 4:59:49 AMJun 23
to Domenic Denicola, blink-dev, Hiroki Nakagawa
Thanks for improving "moderate"!

On Mon, Jun 23, 2025 at 10:54 AM 'Domenic Denicola' via blink-dev <blin...@chromium.org> wrote:

Contact emails

nhi...@chromium.org

Specification

https://wicg.github.io/nav-speculation/speculation-rules.html#:~:text=early%20as%20possible.-,%22moderate%22,balance%20between%20%22eager%22%20and%20%22conservative%22.,-%22conservative%22

Summary

On mobile, "moderate" eagerness speculation rules prefetches and prerenders now trigger when a link enters the viewport and passes other conditions that indicate that it's more likely to be clicked. The previous behavior, of waiting until pointerdown, was the same as "conservative" eagerness. This new behavior is more useful as it better reflects author intent to be more eager than the "conservative" setting. More detail on this and other upcoming improvements to speculation rules eagerness are available at https://docs.google.com/document/d/1YPbtUPfZIDElzBZNx8IQMzRFvy8oauLG_i1XIr6jgTs/edit?usp=sharing.


Are you planning to ship the "simple viewport heuristics", the "complex viewport heuristics", or both?
 
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAM0wra-Y5%3DEZ1yUWA8qg152%2BLz5q_jPTUKMMfg866BvO9DgCZg%40mail.gmail.com.

Domenic Denicola

unread,
Jun 23, 2025, 8:51:16 PMJun 23
to Yoav Weiss (@Shopify), blink-dev, Hiroki Nakagawa
On Mon, Jun 23, 2025 at 5:59 PM Yoav Weiss (@Shopify) <yoav...@chromium.org> wrote:
Thanks for improving "moderate"!

On Mon, Jun 23, 2025 at 10:54 AM 'Domenic Denicola' via blink-dev <blin...@chromium.org> wrote:

Contact emails

nhi...@chromium.org

Specification

https://wicg.github.io/nav-speculation/speculation-rules.html#:~:text=early%20as%20possible.-,%22moderate%22,balance%20between%20%22eager%22%20and%20%22conservative%22.,-%22conservative%22

Summary

On mobile, "moderate" eagerness speculation rules prefetches and prerenders now trigger when a link enters the viewport and passes other conditions that indicate that it's more likely to be clicked. The previous behavior, of waiting until pointerdown, was the same as "conservative" eagerness. This new behavior is more useful as it better reflects author intent to be more eager than the "conservative" setting. More detail on this and other upcoming improvements to speculation rules eagerness are available at https://docs.google.com/document/d/1YPbtUPfZIDElzBZNx8IQMzRFvy8oauLG_i1XIr6jgTs/edit?usp=sharing.


Are you planning to ship the "simple viewport heuristics", the "complex viewport heuristics", or both?

This PSA is for "complex viewport heuristics", the new "moderate" behavior.

Future PSAs will be used for "eager" (which is "simple viewport heuristics" on mobile.)

Gilberto Cocchi

unread,
Jun 30, 2025, 9:59:44 AMJun 30
to Domenic Denicola, Yoav Weiss (@Shopify), blink-dev, Hiroki Nakagawa
This is huge, thanks for improving Speculation Rules moderate behaviour!



--

gTech Up

Gilberto Cocchi
Web Ecosystem Consultant
gilb...@google.com


Google Italy | Via Federico Confalonieri 4 | Porta Nuova Isola | Building C | Milan 20124

Registered in Milan, Italy


This email may be confidential and privileged. If you received this communication by mistake, please don't forward it to anyone else, please erase all copies and attachments, and please let me know that it has gone to the wrong person.

The above terms reflect a potential business arrangement, are provided solely as a basis for further discussion, and are not intended to be and do not constitute a legally binding obligation. No legally binding obligations will be created, implied, or inferred until an agreement in final form is executed in writing by all parties involved.

Reply all
Reply to author
Forward
0 new messages