Skip to main content

django CMS Video

pypi build coverage

django CMS Video is a set of plugins for django CMS that allow you to publish video content on your site (using an HTML5 player by default, but you can override this in your own templates if required).

It uses files managed by Django Filer.

preview.gif

Contribute to this project and win rewards

Because this is a an open-source project, we welcome everyone to get involved in the project and receive a reward for their contribution. Become part of a fantastic community and help us make django CMS the best CMS in the world.

We’ll be delighted to receive your feedback in the form of issues and pull requests. Before submitting your pull request, please review our contribution guidelines.

We’re grateful to all contributors who have helped create and maintain this package. Contributors are listed at the contributors section.

Documentation

See REQUIREMENTS in the setup.py file for additional dependencies:

Supported Python versions Supported Django versions Supported django CMS versions

These badges show the supported versions declared by the latest release on PyPI.

  • Django Filer 1.7 or higher

Make sure django-filer is installed and configured appropriately.

Installation

For a manual install:

  • run pip install djangocms-video

  • add djangocms_video to INSTALLED_APPS in your project’s settings file (usually <project_name>/settings.py)

  • run python manage.py migrate djangocms_video

Configuration

Add all DJANGOCMS_VIDEO_* settings below to your project’s settings file, usually <project_name>/settings.py (the module selected by DJANGO_SETTINGS_MODULE in manage.py).

Note that the provided templates are very minimal by design. You are encouraged to adapt and override them to your project’s requirements.

Custom templates

This addon provides a default template for all instances. You can provide additional template choices by adding a DJANGOCMS_VIDEO_TEMPLATES setting to your project’s settings file:

from django.utils.translation import gettext_lazy as _

DJANGOCMS_VIDEO_TEMPLATES = [
    ('feature', _('Featured Version')),
]

The first value, feature, is the template directory name; the second is the label shown in the plugin’s Template field.

Copy the files from this package’s djangocms_video/templates/djangocms_video/default/ directory into your own app, using this layout (your_app is an app in your project):

your_app/
    templates/
        djangocms_video/
            feature/
                video_player.html
                source.html
                track.html

Ensure your_app is in INSTALLED_APPS and APP_DIRS is True in your existing DjangoTemplates entry in TEMPLATES. If you configure template loaders explicitly instead, include django.template.loaders.app_directories.Loader.

Alternatively, put the same djangocms_video/feature/ directory under a project-level templates/ directory, alongside manage.py. Add that directory to DIRS in your existing DjangoTemplates entry in the project’s settings file, keeping any other directories already configured:

"DIRS": [BASE_DIR / "templates"],

This example assumes BASE_DIR is a pathlib.Path pointing to the directory containing manage.py. Keep the other template settings, including context processors. See Django’s template loading documentation for details.

Edit the copied files, then select Featured Version in the Video player plugin’s Template field. The player loads djangocms_video/feature/video_player.html; its Source and Track child plugins load source.html and track.html from the same directory. Copy all three files so that child plugins can render without a TemplateDoesNotExist error.

To customize the existing Default choice instead, use djangocms_video/default/ in your own templates directory; no DJANGOCMS_VIDEO_TEMPLATES setting is needed. When using app templates for this override, place your_app before djangocms_video in INSTALLED_APPS so Django finds your templates first.

Make changes in your own project or app. Editing the installed package’s files would lose your changes when the package is updated or reinstalled.

Video settings

MP4, WEBM and OGV files are allowed by default. We recommend adding all 3 source files for full browser compatibility. You can change the default setting by overriding:

DJANGOCMS_VIDEO_ALLOWED_EXTENSIONS = ['mp4', 'webm', 'ogv']

The plugin detects YouTube URLs using a regular expression and canonicalizes them to //www.youtube.com/embed/{} where the placeholder is replaced by the video id.

The canonical URL can be reconfigured with a configuration setting:

DJANGOCMS_VIDEO_YOUTUBE_EMBED_URL = '//www.youtube-nocookie.com/embed/{}'
HLS streams

To play an HTTP Live Streaming (HLS) stream, add an HLS Stream Source child to a Video player plugin and enter the HTTP or HTTPS URL of its .m3u8 playlist. Leave the player’s Embed link empty. The Show controls and Autoplay options are available in the player’s advanced settings; browsers may block autoplay.

Streams use the HTML <video> element with hls.js or the browser’s native HLS support. Ensure sekizai is in INSTALLED_APPS, sekizai.context_processors.sekizai is in the template context processors, and the page template loads sekizai_tags and includes {% render_block "js" %} after the content.

By default, hls.js is loaded from a CDN. To use a different URL or a locally hosted copy, override this setting:

DJANGOCMS_VIDEO_HLSJS_SOURCE = 'https://cdn.jsdelivr.net/npm/hls.js@1.5.17/dist/hls.min.js'

Running Tests

You can run tests by executing:

virtualenv env
source env/bin/activate
pip install -r tests/requirements/dj52_cms50.txt
python -m pytest

The HLS playback script tests use Node.js (18 or later) without additional packages:

node --test tests/test_hls_stream_source.js

Metadata

Release files for djangocms-video 3.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for djangocms-video 3.2.0
File Size Uploaded Provenance
djangocms_video-3.2.0.tar.gz 46.3 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for djangocms-video 3.2.0
File Interpreter ABI Platform
djangocms_video-3.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 212.9 kB

Release files / djangocms_video-3.2.0.tar.gz

Download URL djangocms_video-3.2.0.tar.gz
Size 46.3 kB
Tags Source
SHA-256 checksum
How to use checksums
c3b3f65c0f825e34734154037ddf5d216a8c4dedfda87df2cec7828afc855303
BLAKE2b-256 checksum
How to use checksums
0ea77389484826b12451a48116b479cf55483f598fdc928a546d11584c1ece3b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / djangocms_video-3.2.0-py3-none-any.whl

Download URL djangocms_video-3.2.0-py3-none-any.whl
Size 166.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fd6ca250f619b7e99e5f485aff8b1bc94c3f464a123a593d79ed3f47d220d9e8
BLAKE2b-256 checksum
How to use checksums
8f8fd6d108f536d8e7c88dac4feaeda489581bcbae0859803d185be14c84b4df
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Security for djangocms-video 3.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for djangocms_video-3.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page