Web · React, Vue, Svelte, Angular, JavaScript
A React video editor for your web app, in your brand
Also Vue, Svelte, Angular and plain JavaScript.
Put a complete video editor in your web app: preview, desktop timeline, text, effects, music and MP4 export, all in the browser. A hook and two components in React, the same SDK for every framework, and no render server to run.
Building a mobile app with React Native? See the React Native video editor.
What your users get
A desktop timeline
At 900 px and wider: a free playhead, and clips users drag with the mouse.
Keyboard shortcuts
Space, J/K/L, arrows, S, Backspace and ⌘Z, on unless you turn them off.
A preview users arrange
Select a layer, then move, resize and rotate it right in the video.
Effects and transitions
Looks, adjustments and effects on clips, transitions between them, keyframes for motion.
Text and captions
Styled, animated titles, and captions users add in the editor.
Audio
Music and sound on their own tracks, with volume and voice effects.
Try every tool in the live demo.
Edits and exports in the browser
Everything renders in the user's browser. The SDK needs no server of yours or ours to edit or export; the only network request it makes is a license check, at most once a day. Export runs in a worker, so the editor stays smooth while it encodes, and returns the MP4 (H.264 video, AAC audio) as a Blob you can download or upload:
const mp4 = await editor.export({
shortSide: 1080, // or omit for the project's size
onProgress: (f) => setProgress(f),
signal: abortController.signal, // to cancel
})
const link = Object.assign(document.createElement('a'), {
href: URL.createObjectURL(mp4),
download: 'video.mp4',
})
link.click()React: a hook and two components
npm install @nitrakit/react
useNitrakitEditor creates the editor when the component mounts and frees it when it unmounts. NitrakitPreview and NitrakitEditor each render a div the editor fills:
import { useNitrakitEditor, NitrakitPreview, NitrakitEditor } from '@nitrakit/react'
export function VideoEditor() {
const editor = useNitrakitEditor({
width: 1080,
height: 1920,
onRequest: async (request) => {
if (request.kind === 'addMedia') {
const file = await openMyMediaLibrary()
return file ? { source: (await editor!.addMedia(startUpload(file), file)).source } : null
}
// anything else: the built-in picker
},
})
return (
<>
<NitrakitPreview editor={editor} style={{ height: '60vh' }} />
<NitrakitEditor editor={editor} style={{ height: 320 }} />
</>
)
}Callbacks always call your latest version, so they can use current state. The full guide: React video editor component.
Vue, Svelte and Angular
Plain JavaScript
No framework? Use @nitrakit/web directly. Check support, load the WebAssembly module once, then give the preview and the controls an element each:
npm install @nitrakit/web
import { isSupported, load, setLicense } from '@nitrakit/web'
if (!isSupported()) showUnsupportedMessage()
await load()
setLicense('nk2.…')import { createEditor } from '@nitrakit/web'
const editor = await createEditor({
preview: document.getElementById('preview')!,
editor: document.getElementById('editor')!,
width: 1080,
height: 1920, // the project's size: 9:16 vertical video
})With Vite, exclude the package from dependency pre-bundling (optimizeDeps: { exclude: ['@nitrakit/web'] }) so its WebAssembly and font files resolve in development. See JavaScript video editor SDK for the web.
Your files, your storage
On the web the SDK has simple built-in pickers for every request: a file chooser for media, the browser's colour input, and lists for fonts, filters and text styles. They're there to get started. Files from the built-in media picker get random ids and aren't uploaded anywhere, so once you store media, answer onRequest with your own library and resolveMedia with a URL (signed, if you like) for each id. Media from another origin needs CORS. See Your pickers.
Make it look like your app
Browser requirements
| Browser | WebGPU and WebCodecs: recent Chrome or Edge on desktop, or Safari 26. Check with isSupported() and show a message otherwise. |
|---|---|
| Export input | Videos in H.264 MP4. Other formats play in the preview only. |
| Media from other origins | Needs CORS. |
Library, SDK or build it yourself?
You can build video editing on the web from parts: ffmpeg.wasm for processing, WebCodecs for decoding and encoding, a canvas or WebGPU for drawing. Each solves a piece. The editor around them (a timeline, a preview that matches the export, text, undo, pickers, saved projects) is the larger job, and it's the part Nitrakit ships ready to theme.
FAQ
- Does export need a server?
- No. Export runs in a worker in the browser and returns a
Blob. The SDK needs no server of yours or ours. - Which browsers does it support?
- Browsers with WebGPU and WebCodecs: recent Chrome or Edge on desktop, or Safari 26.
isSupported()tells you at runtime. - Can I use my own media library?
- Yes. Answer
onRequestwith your picker and the editor adds what you return. Projects refer to media by your ids. - How big is the download?
- About 1.9 MB with brotli, and the browser caches it. Load the editor when the user opens it so the rest of your app doesn't wait. See App size.
- Can I try it without a license key?
- Yes. Everything works without a key and
localhostalways counts as development; exports are watermarked and up to 15 seconds. A key for your site's origins removes the limits. See pricing. - Is there a React Native version?
- Yes: the React Native video editor, Expo included. There are also native SDKs for iOS and Android.