A free, browser-based Progressive Web App (PWA) for Play , Trim and Edit Videos or create Vine style clips (short clip). client side so everything runs locally in your browser.
- Upload or Select: Choose from a library of trending clips or upload your own video
- Precise Trimming: Frame-accurate video trimming with timeline controls
- Text Overlays: Six short-form-ready text styles (Comic, Neon, Retro, Bold, Elegant, Outline)
- Real-time Preview: See your edits instantly in the browser
- Local Export: Download your finished clips without watermarks
- Full-Featured Player: Play, pause, seek, volume control, and fullscreen
- Keyboard Shortcuts: Space/K to play/pause, arrow keys to seek, M to mute, F for fullscreen
- Offline Support: Play videos stored locally even when offline
- File Handling: Open video files directly from your system (Windows File Handling API)
- Installable: Install as a native app on desktop and mobile
- Offline Capable: Works offline with cached resources and IndexedDB storage
- Fast Loading: Optimized caching strategies for quick access
- App Shortcuts: Quick access to Studio and Gallery from installed app
- 100% Local Processing: All video processing happens in your browser
- No Server Uploads: Your videos never leave your device
- No Signup Required: Start creating immediately
- No Tracking: Privacy-first approach
- Node.js 18+ and pnpm (or npm/yarn)
- Modern browser with support for:
- Web APIs (File API, IndexedDB, Service Workers)
- Video codecs (MP4, WebM, etc.)
- Clone the repository:
git clone https://github.com/alihd-tech/CamCut.git
cd CamCut- Install dependencies:
pnpm install- Start the development server:
pnpm dev- Open your browser and navigate to
http://localhost:5173
pnpm buildThe production build will be in the dist directory, ready to be deployed to any static hosting service.
pnpm previewCanCut/
โโโ src/
โ โโโ components/ # React components
โ โ โโโ VideoPlayer.tsx # Full-featured video player
โ โ โโโ Studio.tsx # Main video editor
โ โ โโโ VideoTrimmer.tsx # Video trimming interface
โ โ โโโ TextEditor.tsx # Text overlay editor
โ โ โโโ VideoPreview.tsx # Preview and export
โ โ โโโ Gallery.tsx # Video gallery
โ โ โโโ LocalVideos.tsx # Local video storage viewer
โ โ โโโ ...
โ โโโ contexts/ # React contexts
โ โ โโโ SettingsContext.tsx
โ โโโ hooks/ # Custom React hooks
โ โ โโโ useOfflineStatus.ts
โ โ โโโ useVideoEditor.ts
โ โโโ lib/ # Utility libraries
โ โ โโโ api.ts
โ โโโ router.tsx # Client-side routing
โ โโโ types/ # TypeScript type definitions
โ โ โโโ video.ts
โ โโโ utils/ # Utility functions
โ โ โโโ videoStorage.ts # IndexedDB video storage
โ โโโ App.tsx # Main app component
โ โโโ main.tsx # Entry point
โโโ public/ # Static assets
โ โโโ videos/ # Sample video clips
โ โโโ manifest.json # PWA manifest
โ โโโ sw.js # Service worker
โโโ dist/ # Production build output
โโโ vite.config.ts # Vite configuration
โโโ tailwind.config.js # Tailwind CSS configuration
โโโ package.json
- Framework: React 18.3.1 with TypeScript
- Build Tool: Vite 5.4.2
- Styling: Tailwind CSS 3.4.1
- Icons: Lucide React
- Animations: Framer Motion
- File Upload: React Dropzone
- PWA: Vite Plugin PWA with Workbox
- Routing: Custom hash-based router
- Desktop: Look for the install prompt in your browser's address bar
- Mobile: Use "Add to Home Screen" from the browser menu
- Windows: Can be installed from Microsoft Edge
- Videos uploaded are stored in IndexedDB for offline access
- App shell and static assets are cached
- Service worker handles caching strategies:
- Videos: CacheFirst (30 days)
- API: NetworkFirst (5 minutes)
- Static assets: StaleWhileRevalidate
- HTML: NetworkFirst (1 day)
- Supports opening video files directly from File Explorer
- Registered file types: MP4, MKV, WebM, MOV, AVI, M4V, 3GP, FLV, WMV, OGV, MPEG, MPG
- Select Source: Choose from library or upload your own video
- Trim: Set in/out points on the timeline (3-6 seconds for short-form)
- Add Text: Type your caption and choose a style
- Preview & Export: Review your clip and download
- Click video to play/pause
- Double-click for fullscreen
- Use control bar for seek, volume, and playback speed
SpaceorK: Play/pauseโ/โ: Seek backward/forward 5 secondsM: Mute/unmuteF: Toggle fullscreen0-9: Seek to percentage (0% to 90%)
- Duration Preference: Choose between short-form (3-6s) or long-form (30+s)
- Theme: Light/dark mode support
- Storage Management: View and manage stored videos
The app uses Vite's environment variables. See vite.config.ts for configuration.
pnpm dev- Start development serverpnpm build- Build for productionpnpm preview- Preview production buildpnpm lint- Run ESLintpnpm typecheck- Run TypeScript type checking
- ESLint for code linting
- TypeScript for type safety
- Prettier (if configured) for code formatting
- Chrome/Edge: Full support (recommended)
- Firefox: Full support
- Safari: Limited PWA support (iOS 11.3+)
- Opera: Full support
The app can be deployed to any static hosting service:
- Vercel: Connect your repository
- Netlify: Drag and drop the
distfolder - GitHub Pages: Use GitHub Actions
- Cloudflare Pages: Connect repository
- AWS S3 + CloudFront: Upload
distfolder
- HTTPS required for PWA features (Service Workers)
- Proper MIME types for video files
- CORS headers if using external APIs
- All video processing happens client-side
- No data is sent to external servers (except API calls if configured)
- Videos stored in IndexedDB remain on your device
- No analytics or tracking by default
Contributions are welcome! Please feel free to submit a Pull Request.
- Preview : Camcut.fun
