Skip to main content

Provisioning where to play content in Broadcast

Updated today

Configuring Video URLs inside Broadcast

To ensure that your users get the most relevant and accurate content, it’s important to configure video URLs correctly within the Broadcast content management table. This article walks you through the basics of URL structure and offers best practices for setting up your widget for optimal performance and user experience.


Understanding URL Structure and Query Parameters

A URL (Uniform Resource Locator) is the address of a web page. It typically looks like this:

https://example.com/page?userId=123&ref=campaign

This URL consists of two main parts:

  1. URL Path – The core structure of the webpage:
    https://example.com/page

  2. Query Parameters – Extra information added to the URL after a ?:
    ?userId=123&ref=campaign

Each query parameter is usually used to pass dynamic data like user information, campaign IDs, or feature toggles. While these are useful for tracking or customization, they don’t always affect the actual content the user sees on the page.


Widget Configuration Settings

When configuring how videos are matched to URLs on your site via the widget, there are two primary settings to consider:

1. Content Recommendations: Show Only Exact URL Match

Recommended if you want full control over content display.

  • When enabled, the Broadcast widget only shows videos for exact matches between the current URL and the one configured in the admin panel.

  • Ideal for static or clean URL structures where you know exactly where content should appear.

Example:

If you configure a video to show on:

https://example.com/math/algebra

It will not appear on:

https://example.com/math/algebra?userId=123

This ensures your content only appears exactly where it’s intended.


2. Query Params: Include Query Params

🔄 Controls whether the widget should react to changes in query parameters in the URL.

This setting affects the entire widget, not just a single video configuration. That means it determines whether any change in the query string (e.g., ?userId=123) will trigger the widget to update the displayed recommendations.

🔧 When to Use It

Enable this setting only if your site has pages where query parameters significantly change what the user sees (e.g., switching lessons, tabs, or content sections).

Example:

https://example.com/course?lesson=5

If changing the lesson parameter dynamically updates the content of the page, you should turn this setting on so the widget can adjust recommendations accordingly.

🚫 When Not to Use It

If your site uses query parameters for tracking, personalization, or user data—but those parameters don’t influence what’s actually shown on the page—you should turn this setting off.

Otherwise, the widget will refresh unnecessarily every time the URL changes, possibly creating a jumpy or flickering experience for your users.

Example (bad match, no UI change):

https://example.com/math/algebra?userId=123&ref=campaign

In this case, userId and ref don’t affect the visible content. So, having "Include Query Params" enabled might cause the widget to reload needlessly even though the page stays the same.

If none of your pages rely on query parameters to change visible content, disable this setting globally. It will result in a smoother experience and better performance for your users


Best Practices for Configuring URLs for Videos

To make sure your educational videos display correctly and efficiently, follow these tips:

✅ Use Only the URL Path If Possible

Whenever you can, configure video URLs using just the path portion without query parameters. This makes it easier to manage and reduces the chance of mismatches.

Example:

  • Use: /math/algebra

  • Avoid: /math/algebra?userId=123&sessionId=abc

🧹 Include as Few Query Parameters as Possible

If your site relies on query parameters to change the visible content, include only those necessary for defining the context. Avoid excess or unrelated data in the URL.

Better:

/course?lesson=5

Worse:

/course?lesson=5&userId=8923&ref=twitter&theme=dark

🔒 Remove All User-Related Query Params

Query parameters like userId, authToken, or sessionId should never be used in video URL configurations. They are unique to each user and can prevent your videos from displaying correctly for others.

Instead of this:

/topic/biology?userId=2345

Use this:

/topic/biology


Summary

Setting / Practice

When to Use

Why It Matters

Show only exact URL match

You want strict control over where videos appear

Prevents accidental matches

Include query params

Your page content truly changes based on query parameters

Enables dynamic recommendations

Use only the URL path

Content is always the same regardless of query params

Simpler and more reliable matching

Remove user-related query parameters

Personal data in URL doesn’t affect content

Reduces errors and improves consistency

Did this answer your question?