PHPackages                             deuxhuithuit/craft-cloudflare-stream - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Image &amp; Media](/categories/media)
4. /
5. deuxhuithuit/craft-cloudflare-stream

ActiveCraft-plugin[Image &amp; Media](/categories/media)

deuxhuithuit/craft-cloudflare-stream
====================================

Upload your videos assets to Cloudflare Stream from Craft CMS assets interface

2.3.0(2mo ago)11.1k↓100%2[2 issues](https://github.com/DeuxHuitHuit/craft-cloudflare-stream/issues)proprietaryPHPPHP 8.2.\*|8.3.\*|8.4.\*CI passing

Since Jul 24Pushed 2mo ago2 watchersCompare

[ Source](https://github.com/DeuxHuitHuit/craft-cloudflare-stream)[ Packagist](https://packagist.org/packages/deuxhuithuit/craft-cloudflare-stream)[ RSS](/packages/deuxhuithuit-craft-cloudflare-stream/feed)WikiDiscussions dev Synced 1mo ago

READMEChangelog (10)Dependencies (5)Versions (35)Used By (0)

Craft CMS Cloudflare Stream
===========================

[](#craft-cms-cloudflare-stream)

> This plugin offers a easy way to upload your videos assets from Craft CMS to Cloudflare stream.

Installation
------------

[](#installation)

1. Install with composer

```
composer require deuxhuithuit/craft-cloudflare-stream
```

2. Install in craft

```
craft plugin/install cloudflare-stream
```

3. Add your account id and api token in the settings. You can (and should) use env vars. Make sure to also choose your upload mechanism. If your volume does not have public urls, turn on form data upload. This is the recommended value, but not the default since not all hosts allows it.
4. Create a new File System and a new Volume specific for streams. This is safer and will also allow you to turn off public urls as they are not required for streams to work.
5. Create a new video stream Field and add it to your Asset data model.
6. When editing an asset, you can now opt-in into sending videos in [Cloudflare Stream](https://www.cloudflare.com/products/cloudflare-stream/). You can also enable auto-upload of stream in the settings.
7. If your are using twig, with a field named `stream` you can access the stream data like so:

```
{% set value = asset.stream %}

    {% if value.mp4Url and value.completed %}

    {% endif %}
    {% if value.playback.hls %}

    {% endif %}
    {% if value.playback.dash %}

    {% endif %}

```

8. If you are using graphql, there is a type registered to make it easy to request the proper data.

```
query MyQuery {
  asset(site: ["en"], volume: "stream") {
    url
    kind
    extension
    filename
    ... on stream_Asset {
      videoStream {
        uid
        name
        size
        thumbnailTimestampPct
        thumbnail
        preview
        hls
        dash
        mp4
        ready
        completed
        watermark {
          uid
          created
          downloadedFrom
          height
          name
          opacity
          padding
          position
          scale
          size
          width
        }
        input {
          width
          height
        }
      }
    }
  }
}
```

9. You can also mass re-upload everything via Craft's cli. Please note that this creates *new* streams videos and is useful mainly when changing accounts.

```
./craft cloudflare-stream/reupload
```

This extension uses Craft's Queue system, so make sure it works properly.

Dealing with large files
------------------------

[](#dealing-with-large-files)

Videos can be quite large, which makes uploading them a little trickier. Please make sure that Craft's and php's max upload limit are properly set.

If you still want to deal with larger file than what your host allows, you might want to try the [Chunked Upload plugin](https://plugins.craftcms.com/chunked-uploads)to bypass your host restrictions. The plugin will use TUS when appropriated. The chunk size can be set by setting the `CF_STREAM_TUS_CHUNK_SIZE` env var to a value in bytes, in the 5 to 200 Mb range.

Made with ❤️ in Montréal.

(c) Deux Huit Huit

###  Health Score

47

—

FairBetter than 94% of packages

Maintenance65

Regular maintenance activity

Popularity22

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity73

Established project with proven stability

 Bus Factor1

Top contributor holds 95.7% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~28 days

Recently: every ~124 days

Total

34

Last Release

79d ago

Major Versions

1.5.0 → 2.0.02024-08-13

1.6.1 → 2.1.02024-10-02

1.6.2 → 2.2.02024-10-23

PHP version history (5 changes)1.0.0PHP 8.1.\*|8.2.\*

1.2.7PHP ^8.1|^8.2

1.4.6PHP ^8.1|^8.2|^8.3

2.0.0PHP 8.2.\*|8.3.\*

2.2.2PHP 8.2.\*|8.3.\*|8.4.\*

### Community

Maintainers

![](https://www.gravatar.com/avatar/d9dd0ccaee103d53ba8a49b4d4918c2f1489da0f6c6fc173051576230ce615ae?d=identicon)[nitriques](/maintainers/nitriques)

---

Top Contributors

[![nitriques](https://avatars.githubusercontent.com/u/771169?v=4)](https://github.com/nitriques "nitriques (90 commits)")[![curtishenson](https://avatars.githubusercontent.com/u/15751?v=4)](https://github.com/curtishenson "curtishenson (2 commits)")[![f-elix](https://avatars.githubusercontent.com/u/47465520?v=4)](https://github.com/f-elix "f-elix (1 commits)")[![patrick-long](https://avatars.githubusercontent.com/u/78626999?v=4)](https://github.com/patrick-long "patrick-long (1 commits)")

---

Tags

craft-plugincraftcmscraftcms-pluginhacktoberfeststreamvideocloudflarecraft cms

###  Code Quality

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/deuxhuithuit-craft-cloudflare-stream/health.svg)

```
[![Health](https://phpackages.com/badges/deuxhuithuit-craft-cloudflare-stream/health.svg)](https://phpackages.com/packages/deuxhuithuit-craft-cloudflare-stream)
```

###  Alternatives

[php-ffmpeg/php-ffmpeg

FFMpeg PHP, an Object Oriented library to communicate with AVconv / ffmpeg

5.0k21.7M163](/packages/php-ffmpeg-php-ffmpeg)[danog/madelineproto

Async PHP client API for the telegram MTProto protocol.

3.4k855.0k18](/packages/danog-madelineproto)[vimeo/vimeo-api

Official PHP library for the Vimeo API.

4637.1M32](/packages/vimeo-vimeo-api)[vimeo/laravel

A Vimeo bridge for Laravel

4161.5M4](/packages/vimeo-laravel)[opentok/opentok

OpenTok is a platform for creating real time streaming video applications, created by TokBox.

1413.0M10](/packages/opentok-opentok)[dereuromark/media-embed

A PHP library to deal with all those media services around, parsing their URLs and embedding their audio/video content in websites.

182530.3k11](/packages/dereuromark-media-embed)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
