Programmable Media

Upload videos in Node.js (video tutorial)

Last updated: Oct-29-2024

Overview

Learn how to upload videos in Node.js using the Cloudinary Node.js SDK.

Video tutorial


View the code
You can find the code from this tutorial in GitHub.

Tutorial contents

This tutorial presents the following topics. Click a timestamp to jump to that part of the video.

Install and configure the Node.js SDK

Jump to this spot in the video  0:20 You need to install and configure the Cloudinary Node.js SDK with your product environment credentials.

Upload a video using the Node.js SDK

Jump to this spot in the video  0:28 Upload a video from a local folder using the upload method of the Upload API. Use the await keyword to get the result and print the delivery URL of the uploaded video.

Run the script from the terminal

Jump to this spot in the video  1:02 Run the script from the terminal and then paste the URL in a browser to see the video.

Use the upload large method for big videos

Jump to this spot in the video  1:18 Use the upload_large method to upload big videos using chunks. The method does not return a promise, but you can wrap the code with your own promise and await the response.

Run the script again from the terminal

Jump to this spot in the video  2:04 Run the script from the terminal to upload the big video (the script takes a bit longer to run), and then paste the URL in a browser to see the video.

Keep learning

Related topics

If you like this, you might also like...

Configure the Node.js SDK
Install and configure the Cloudinary Node.js SDK
Upload Images in Node.js
Upload images to Cloudinary using the Node.js SDK
Upload Widget
Embed an Upload Widget in your site

 

Cloudinary Academy

 

Check out the Cloudinary Academy for free self-paced Cloudinary courses on a variety of developer or DAM topics, or register for formal instructor-led courses, either virtual or on-site.

 

✔️ Feedback sent!

Rate this page: