External Playlists and RSS & JSON Feeds

As of JW Player 7.3, it is possible to load either a basic XML, or a JSON-formatted playlist file. Each of these cases is used to load a playlist with one or more media items into JW Player. For each entry, JW Player can read metadata, poster image, media sources and text tracks from the feed. Loading of external feeds differs slightly from our single file example, since it uses the playlist option instead of file.

RSS Feeds

An RSS feed is a basic XML file, used to load a playlist with one or more media items into JW Player. For each entry, JW Player can read metadata, poster image, media sources and text tracks from the feed. Loading of RSS feeds differs slightly from other formats, since they use the playlist option instead of file.

For single video embeds, external RSS feeds are useful for larger scale media deployments, due to the separation of presentation (config options) and content (RSS feed). External RSS is also useful when working with third-party content providers, directly loading the RSS feeds off their servers (e.g. for podcasts/vodcasts).

Mapping Table

JW Player supports RSS feeds using the JWPlayer RSS namespace (preferred), the Media RSS namespace or vanilla RSS 2.0 with enclosures. Not all item, source and track attributes are supported with Media RSS and plain RSS. Below is how all configuration options map to JWPlayer RSS, Media RSS and vanilla RSS:

Inline Playlist RSS with JWPlayer RSS with Media vanilla RSS
title title title title
description description description description
mediaid guid guid guid
image jwplayer:image media:thumbnail@url -
source.file jwplayer:source@file media:content@url enclosure@url
source.label jwplayer:source@label - -
source.default jwplayer:source@default - -
source.type jwplayer:source@type media:content@type enclosure@type
track.file jwplayer:track@file media:subtitle@url -
track.kind jwplayer:track@kind - -
track.label jwplayer:track@label - -
track.default jwplayer:track@default - -

JW Player supports playback of multiple media formats: video files, audio files, RSS/JSON playlists, and adaptive streams.

JSON Feeds

External JSON feeds are formatted in much the same way as our embedded playlists. An example of a .json feed appears below:

  "file": "myvideo.mp4",
  "image": "myposter.png",
  "title": "My Video",
  "mediaid": "123456"
  "file": "myvideo.mp4",
  "image": "mysecondposter.png",
  "title": "My Second Video",
  "mediaid": "234567"

Let's assume that the above code is inside of a playlist.json file. Using this within a simple embed would appear as:

var playerInstance = jwplayer("myElement");
playlist: "playlist.json"


An example of the player utilizing an RSS playlist can be seen below:


Although many playlist formats are available (e.g. ASX, ATOM, M3U, XSPF), JW Player only supports RSS. JW Player can play basic RSS feeds (using the <enclosure> tag), as well as RSS feeds using the MediaRSS or JW Player extensions. Services that produce compatible RSS feeds include JW Platform, iTunes, and Blip.tv.

Step 1: Configuring your JW Player Library

JW Player offers two options for configuring your player's library on your web page:

Option A: Add a library to your <head>

In order to embed media with JW Player, you first have to add the player library to the head of your HTML page(or elsewhere above the actual embed). Player libraries are found in your embedding wizard and will set player defaults according to what is specified in the Wizard. A player's library will appear similarly to:

<script src="//content.jwplatform.com/libraries/eX4mp13.js"></script>

Note: The above library can be reached via HTTPS by changing http to https in the URL

JW Player libraries are cloud-hosted by us, making them fast, reliable, secure, and always up-to-date with our latest releases. In addition, all configuration is performed with our easy-to-use graphical interface via our Dashboard.

Option B: Self-hosting

If you want to host your own player library, you can find both your license key and latest JW Player files in your dashboard's Advanced Account page. Once downloaded, you will need to host jwplayer.js on your own server. When configuring your web page, you will then need to point to your copy of jwplayer.js and also define your self-hosted license key. Here's a code example:

​<script src="//mywebsite.com/jwplayer/jwplayer.js" ></script>

Note: JW Player 7 now requires a license key. Please make sure to include this on your page if you are self-hosting.

Step 2: Create the playlist RSS Feed

With the player library set up, it's time to move on to the playlist. JW Player loads external playlists using the RSS feed format. It is a basic XML format supported by many web services. You can also host these files on your own server. Here is a short example (with just one video to keep things short):

<rss version="2.0" xmlns:jwplayer="http://rss.jwpcdn.com/">

    <title>Sintel Trailer</title>
    <description>Sintel is a fantasy CGI from the Blender Open Movie Project.</description>
    <jwplayer:source file="/assets/sintel.mp4" />


This RSS feed is using the JWPlayer extension to load media file and poster image. JW Player also supports feeds that use the Media extension, or vanilla feeds using enclosures. See the Media Formats Reference for more information.

Note that RSS feeds are subject to cross-domain security restrictions and therefore won't automatically load from another domain than the player. You need to setup CORS headers to fix this issue. See Crossdomain File Loading for more info.

Step 3: Add the embed code to your <body>

With the RSS feed ready to go, it's time to actually embed it. Therefore, insert this HTML in your page, at the exact location you want the player to appear:

<div id="myElement"></div>
var playerInstance = jwplayer("myElement");
  playlist: "//example.com/uploads/myPlaylist.rss",
  width: 640,
  height: 360

In this code, the <div> element is used as a container to load JW Player into. It must have a unique id attribute. The setup() block defines which playlist to load, as well as the width and height of the player in pixels.

Two common mistakes prevent smooth playback of videos in Internet Explorer 9+. First, always start your HTML document with <!DOCTYPE html> to prevent triggering IE's quirks mode. Second, serve up your videos with the video/mp4 mimetype or IE will refuse to play them.

Next Steps

Now that you have configured a basic player embed, you can start looking into adding further customizations. See the Customization section for more information.

If you are still having problems getting things to work, see our troubleshooting guide for a walkthrough of common embedding issues.

Did you find this article helpful?

Please log in to rate this article.