Last updated: November 29, 2024

<span aria-hidden="true" id="real-time-encoding---over-150x-faster"></span>

# Real-time encoding - over 150x faster

![Kevin van Zonneveld](/assets/images/teammates/avatar-kvz-4.jpg?dpl=dpl_EaRBV7VUa5qo1qfBKDnoq2VsKW7d)

**Kevin van Zonneveld**

Co-founder · Amsterdam, The Netherlands · Show bio

[](https://x.com/kvz)[](https://github.com/kvz)

Today we are excited to announce a big new feature: real-time encoding.

Real-time encoding allows your videos to be encoded while they are still uploading. Since our servers can encode video files much faster than most of your users can upload it, they will no longer have to wait for the encoding process to finish after uploading a video. As you can see in the screencast above, this effectively amounts to a 150-fold increase in encoding speed.

Existing customers can enable this feature by simply adding `"realtime": true` to their video encoding Step. We have also updated the [docs](/docs/robots/video-encode.md) for this feature.

If you are new to Transloadit, you can get your hands on this by [signing up](/c/signup/).

<span aria-hidden="true" id="technical-details"></span>

## Technical details

From a technical perspective, real-time encoding works by pumping the video upload stream into FFmpeg via standard input.

While this sounds easy in theory, it is rather difficult to pull off on most stacks. Luckily, our system is built on [Node.js⁠](https://nodejs.org/), which is very well equipped for this kind of stream redirection.

To make it happen, we are using our handcrafted[file upload parser⁠](http://debuggable.com/posts/parsing-file-uploads-at-500-mb-s-with-node-js:4c03862e-351c-4faa-bb67-4365cbdd56cb), which writes the uploaded file to disk and gives us progress events along the way. Each progress event feeds a new chunk of the video into FFmpeg. However, if FFmpeg can't keep up, we wait for the standard input stream to drain. This way, there can never be any sort of memory build-up.

Dealing with errors is also important. If FFmpeg gives us an error during the real-time encoding, we simply abandon it and fall back to the regular encoding.

In short, that is how it works. If you are interested in more details, just leave a[comment⁠](https://twitter.com/transloadit). In case you are already heavily invested in your own video stack, we are also available for consulting to bring this technology to your platform. Just[contact us⁠](mailto:hello@transloadit.com).

<span aria-hidden="true" id="whats-next"></span>

## What's next

This is just one of the Steps to bring streaming functionality to all parts of our service. The next thing we need to tackle is streaming real-time encoded videos to amazon S3.

Another challenge lies in certain `"mov"` files that have their metadata at the end of the file. Luckily we got [Daniel G. Gaytor⁠](https://github.com/danielgtaylor) excited about this, which prompted him to port his [python version⁠](https://github.com/danielgtaylor/qtfaststart) of qtfaststart to [JavaScript⁠](https://github.com/danielgtaylor/qtfaststart.js). We are therefore confident that all of this will get sorted out with the next upgrade of our jQuery SDK.

We would also like to let you know that Daniel is currently looking for a remote job, so you should contact him if you are looking to add a really smart hacker to your team.

<span aria-hidden="true" id="final-thoughts"></span>

## Final thoughts

Our mission is to improve file uploading on the web, so please let us know what other aspects of it are ruining your day - we will be happy to build the solution!

**Credits**

The example video uploaded in the screencast was produced by our friends at[némata⁠](https://nemata.com/).

[#handling-uploads-service](/blog/tags/handling-uploads-service.md)[#performance](/blog/tags/performance.md)[#realtime](/blog/tags/realtime.md)[#video-encode-robot](/blog/tags/video-encode-robot.md)

### 👩‍💻 Join 20k+ developers

Sign up for our [monthly newsletter](/newsletters.md) to receive direct links to 3 exclusive tech — and 2 product updates. No less, no more.

Your email:

Get access

## File uploading and encoding. Made simple.

Transloadit streamlines file handling for developers, trusted by brands like Coursera and The New York Times. We’re known for a reliable API, top-notch support, and a strong commitment to open source, with projects like [Uppy⁠](https://uppy.io) and [Tus⁠](https://tus.io) setting standards in file processing.

[Sign up](/c/)[Book a Demo](https://survey.typeform.com/to/kRg47Xi5)

No credit card needed

Cancel anytime
