MENU
Video
You can either host videos yourselves on your server, or use an external video platform such as YouTube.
While third-party video hosts offer many benefits, self-hosting videos in Next.js offers full control, customization, better performance scalability, and seamless integration -- ideal for tailored needs while balancing cost and independence from third-party platforms.
YouTube 9 is a very popular video host. On your website, you can embed videos hosted on YouTube for free.

Vercel Blob 11834 offers 1GB of free storage. It works very well with Next.js. You can host your videos here:

Access to Vercel Blob has been blocked here because this app is not hosted on Vercel.
Using <Suspense> improves the user experience by allowing the page to remain interactive while the video component loads, preventing any blocking during the streaming process.
Using <Suspense> improves the user experience by allowing the page to remain interactive while the video component loads, preventing any blocking during the streaming process.
Next Video 11834 is a React component that makes it easy to add videos to your Next.js app. It extends the native <video> element with powerful features for seamless video optimization and playback:
- Smart storage: Keep large video files out of your Git repo.
- Auto optimization: Automatically optimize videos and deliver them via CDN for faster, smoother playback.
- Customizable UI: Choose built-in themes or create your own player controls.
- Posters & previews: Get instant placeholder images and timeline hover thumbnails — no setup needed.
- Broader compatibility: Play videos that aren't natively supported by all browsers.
- Built-in analytics (optional): Track video views and performance metrics effortlessly.
- AI-powered enhancements: Automatically generate captions and transcripts for your videos.
To set up Next Video in your Next.js project, run:
npx -y next-video init
This will:
- Install next-video as a dependency.
- Update your next.config.js.
- Add video import types if you're using TypeScript.
- Create a /videos folder for your video files.
- Update .gitignore to exclude video files (recommended to avoid tracking large files in Git).

Vercel recommends using a dedicated video platform to avoid large bandwidth usage. By default, next-video integrates with Mux, a developer-friendly video API used by major platforms like Patreon. To connect Mux 4695 :
- Sign up for Mux.
- Create an access token.
MUX_TOKEN_ID=[YOUR_TOKEN_ID]
MUX_TOKEN_SECRET=[YOUR_TOKEN_SECRET]
You can also modify the package.json script to automatically sync videos as they're added to /videos while the dev server is running.
Try to avoid using turbopack as it can prevent video imports.
"scripts": {
"dev": "next dev & npx next-video sync -w",
},

import Video from 'next-video';
import awesomeVideo from '../videos/movie3.mp4';
export default function Page() {
return <Video src={awesomeVideo} />;
}
Also take a look at:
- FFmpeg 13144 : A complete, cross-platform solution to record, convert and stream audio and video.
- Vercel Edge Network 11834 : Store content close to your customers and compute in regions close to your data, reducing latency and improving end-user performance..
- Cloudinary : High-performance image and video delivery and uploading at scale in Next.js.
- Fastly 8594 : Deliver exceptional on-demand video experiences.
- ImageKit 11464 : Real-time image & video resizing, automatic optimization, and file uploading in Next.js using ImageKit.io.