Float on scroll


Keeps the player visible when the original player location is scrolled out of view by minimizing it to a corner of the screen

On devices in portrait orientation, the player becomes fixed to the top of the page using its original dimensions.

When floating, the viewer can drag the player to reposition it. This functionality is disabled during ad playback.

By default, adding an empty floating object enables the floating player functionality and also sets dismissible: true.

Use the following CSS classes to customize the floating player:

You can also use the floating API method to create custom floating timing.

🚧

Float on scroll cannot be used with a player that is embedded in an iframe.


jwplayer("myElement").setup({
    "playlist": "https://cdn.jwplayer.com/v2/playlists/{playlist_id}",
    ...
    "floating": {
        "dismissible": true
    }
});
Property Description
dismissible boolean Permits or prohibits closing the floating player

Possible values:
  • true: (Default) Floating player can be closed by a viewer.
  • false: Floating player cannot be closed by a viewer.
mode < 8.17.0+ string Tells the player how the floating behavior should operate

Possible values:
  • notVisible: (Default) Begin floating when the player has scrolled off screen and stop floating when it scrolls back onscreen. On mobile devices, floating is not activated if the viewer scrolls above the player on the page (only below it).
  • always: Always float the player
  • never: Never float the player
showTitle boolean Determines if the video title is displayed with the floating player close (X) button

Possible values:
  • false: (Default) The video title is not displayed on the external close bar.
  • true: The video title is displayed on the external close bar.