Cloudflare R2 file manager on Cloudflare Pages (API via Pages Functions) — free 10 GB storage and 100,000 invocations per day. R2 pricing
Pages, not Workers. This repo sets
pages_build_output_dirinwrangler.tomland has no Workermain. Do not use the Workers Deploy to Cloudflare button orwrangler deploy— that looks for a Worker entry point and fails with «entry point not configured».
Grid light:
Grid dark:
Image preview:
Share (expiry + extract code):
- Chunked web uploads, folders, search, drag-and-drop, image/video/PDF thumbnails
- Share links with expiry or forever, extract code, folder zip, and a zero-JS landing page
- Recycle bin with configurable retention (
TRASH_RETENTION_DAYS) - WebDAV Class 1/2 at
/webdav(toggleable without affecting the web UI) - API keys for scripted upload / download / sync, plus remote MCP at
/mcp(25 tools) - Static sites and image host on a separate hostname (
SITES_HOST), plus a GitHub Action to deploy from CI - Owner Settings with five persistent feature switches
davflare-cli, optional Chrome MV3 extension, and agent layouts on R2- Chinese / English UI
- Open Workers & Pages → Create → Pages → Connect to Git, pick this repo (needs a Cloudflare account with R2 activated and a payment method on file).
- Framework preset None, build
npm run build, output directorybuild(or rely onwrangler.toml'spages_build_output_dir). - Bind your R2 bucket to
BUCKET, setWEBDAV_USERNAMEandWEBDAV_PASSWORD, then retry deploy. - Optional:
WEBDAV_PUBLIC_READ=1,TRASH_RETENTION_DAYS(default30,-1disables), and for public sites/images bindsites.<your-domain>and setSITES_HOST=sites.<your-domain>. - Optional: add a custom domain for the drive UI.
Full Pages / Wrangler steps and the five feature switches: docs/deploy.md.
| Topic | Link |
|---|---|
Deploy, env vars, feature switches, post-deploy #/setup checklist; MCP playground #/mcp |
docs/deploy.md · docs/API.md |
| WebDAV clients & limits | docs/webdav.md |
| Open API & MCP (incl. chat share / zip folder examples) | docs/API.md |
| Static sites & image host | docs/sites.md |
GitHub Action — deploy a build dir to a site (uses: fanchenggang/Davflare@main) |
docs/sites.md#github-action-deploy-to-davflare-site |
Agent layouts (pull / push) |
docs/agents.md |
CLI (davflare-cli) |
cli/README.md |
| Chrome extension (install + bookmarks) | extension/README.md |
| Bookmark portability | docs/bookmarks-portability.md |
| Testing | TESTING.md · TEST_CASES.md |
- longern/FlareDrive by longern — original fork; this project has been fully rewritten since. Internal object prefix is still
_$flaredrive$/. - r2-webdav by abersheeran — WebDAV implementation.
- HamHome by bingoYB — bookmark library UX was inspired by this open-source reference.



