What is Video to Base64 Converter?
This video to Base64 converter works in both directions. In Encode mode, choose a video file of up to 25 MB, such as MP4, WebM or OGG, and get it as a Base64 data URI that can be embedded directly in HTML or sent inside JSON.
In Decode mode, paste Base64 video data, choose the video format, and the video appears in a built-in player so you can watch it, with a button to download it as a file. It is useful for short clips such as animations and screen captures, and for debugging video stored or transmitted as Base64.
How to use Video to Base64 Converter
- Choose Encode to convert a video file, or Decode to turn Base64 back into video.
- To encode, select a video file up to 25 MB and copy the Base64 data URI.
- To decode, paste the Base64 string and choose MP4, WebM or OGG.
- Play the video in the player and click Download Video to save it.
Key features
- Encode video files up to 25 MB to Base64
- Decode Base64 back to playable video
- Built-in video player for decoded clips
- MP4, WebM and OGG formats
- Download decoded videos
- Runs entirely in your browser
Common use cases
- Embedding short looping clips in single-file HTML demos
- Recovering video returned as Base64 by APIs or stored in databases
- Sending short clips inside JSON payloads
- Debugging Base64-encoded screen recordings and previews
- Testing video playback of generated clips
Technical details & standards
Encoding reads the file locally with the FileReader API and produces a data URI with the file's MIME type; Base64 makes it about 33% larger than the original. Decoding converts the Base64 into bytes and plays them through an HTML video element with the MIME type you select, which must match the actual format.
Base64 video is practical only for short clips: unlike a normal video file, a data URI cannot be streamed or loaded in ranges, so the whole thing must download before playback, and it cannot be cached separately from the page. The 25 MB limit keeps memory use reasonable. Nothing is uploaded.
Frequently asked questions
How do I convert Base64 to MP4?
Choose Decode, paste the Base64 string and select MP4. The video plays in the built-in player; click Download Video to save it as a file.
How do I play Base64 video in HTML?
Use the data URI as the video source: <video controls src="data:video/mp4;base64,…"></video>. Keep such clips short, because the whole video must load before it plays.
Why is there a 25 MB limit?
Base64 data is held in memory and is a third larger than the file, so large videos make the page slow. For big files, host the video normally or use a streaming service.
Why won't my decoded video play?
The selected format may not match the data, or the Base64 may be truncated. Try another format, and check for extra quotes or escaped characters copied from JSON.
Is my data safe?
Processing happens locally in your browser. Tool input is not sent to CodeUnpack servers.
Does it work offline?
Once the page has loaded, this tool can process input without an internet connection.