Best practice using videos on nextjs
Answered
Sloth bear posted this in #help-forum
Sloth bearOP
Hello, I'm making a project that includes approximately five videos, each about 20MB in size. I'm wondering about the best practices for handling these videos in terms of hosting and optimization For images I know converting from .png to .webp is a common practice but I'm not sure what the best practices are for videos I haven't worked with video in ages. I'm hosting my project on vercel btw
Answered by @ts-ignore
If you are using vercel, I would suggest you to not add video as static asset on vercel as it will take up bandwidth. Instead use a storage bucket like s3 or r2
11 Replies
@Sloth bear Hello, I'm making a project that includes approximately five videos, each about 20MB in size. I'm wondering about the best practices for handling these videos in terms of hosting and optimization For images I know converting from .png to .webp is a common practice but I'm not sure what the best practices are for videos I haven't worked with video in ages. I'm hosting my project on vercel btw
If you are using vercel, I would suggest you to not add video as static asset on vercel as it will take up bandwidth. Instead use a storage bucket like s3 or r2
Answer
Himalayan
welp
i already have like 60x 60mb vids on my website
☠️
American Crow
60 mb sounds like the wrong video format what are you using
or are they very long
Himalayan
they are 1-2 minutes long
each
@Sloth bear Hello, I'm making a project that includes approximately five videos, each about 20MB in size. I'm wondering about the best practices for handling these videos in terms of hosting and optimization For images I know converting from .png to .webp is a common practice but I'm not sure what the best practices are for videos I haven't worked with video in ages. I'm hosting my project on vercel btw
American Crow
if you want to catch up with video codec, compression, etc, theo summoirzed it pretty well:
https://www.youtube.com/watch?v=pX2L_UAIoME
https://www.youtube.com/watch?v=pX2L_UAIoME
Thank you bro