WP Manifestindependent plugin directory
manifest / media / wp-swift-hls

Swift HLS

A lightweight, self-hosted WordPress HLS video player for live streaming. Uses Video.js to ensure native HLS playback.

★ 0stars

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/romiko/wp-swift-hls/archive/refs/heads/main.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

A lightweight, high-performance HLS player for WordPress utilizing a self-hosted instance of Video.js. Swift HLS is specifically optimized to resolve native HLS playback race conditions on Android Firefox, ensuring smooth, consistent video streaming across all mobile and desktop browsers without relying on third-party CDNs.

Features

  • Android Firefox Compatibility: Injects stream sources dynamically via JavaScript to bypass browser-specific HLS loading errors.
  • Self-Hosted Assets: Ships with local Video.js CSS and JS, ensuring maximum privacy, control, and performance.
  • Legacy Shortcode Support: Seamlessly replaces existing [bzplayer] or [bzplayer_free] tags without requiring you to rewrite existing posts.
  • Content Protection: Includes basic right-click prevention on the video element.
  • Fully Responsive: Fluid layouts that adapt perfectly to any screen size.
  • Developer Friendly: Built with WordPress filter hooks (swift_hls_player_config) for easy extensibility.

Installation

  1. Download the latest release.
  2. Upload the swift-hls folder to your /wp-content/plugins/ directory.
  3. Activate the plugin through the 'Plugins' menu in WordPress.
  4. Ensure the assets/ directory is populated with video-js.min.css and video.min.js.

Usage

Embed an HLS stream anywhere on your site using the primary shortcode:

[swift_hls hls="[https://your-domain.com/stream.m3u8](https://your-domain.com/stream.m3u8)" poster="[https://your-domain.com/poster.jpg](https://your-domain.com/poster.jpg)" autoplay="true" muted="true"]

Supported Attributes:

hls (required): The absolute URL to your .m3u8 stream.

poster (optional): URL to a splash image to show before the video initializes.

autoplay (optional): true or false (default: true). Note: Modern browser policies require videos to be muted to autoplay successfully.

muted (optional): true or false (default: true).

Customise

You can modify the core Video.js configuration array before it is passed to the frontend by hooking into the swift_hls_player_config filter.

add_filter('swift_hls_player_config', 'my_custom_swift_config', 10, 2);

function my_custom_swift_config($config, $atts) {
    // Add custom configuration, analytics, or UI elements here
    $config['playbackRates'] = [0.5, 1, 1.5, 2];
    return $config;
}

Swift HLS Pro (Coming Soon)

A premium version is currently in development for high-demand streaming environments. Planned features include:

Advanced stream analytics and viewer metrics.

Custom player branding, UI skins, and watermarks.

DVR controls and enhanced live-ui configurations.

Priority support.