Skip to content

About

Native OOXML engines in Rust - DOCX, XLSX & PPTX editing, rendering and real-time collaboration, compiled to WASM for the web.

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

 
 

Repository files navigation

BetterOffice: the open-source office suite, built on native OOXML engines in Rust

Rust-native OOXML engines with collaboration and agent editing at the core.
WebAssembly for browsers. Headless APIs for servers. Native Rust where you need it.

license npm downloads crates.io downloads PyPI downloads betteroffice.dev

Features

  • Documents, spreadsheets, and slides. Open, edit, render, and save DOCX, XLSX and PPTX files with high fidelity. Native OOXML editing preserves untouched file parts losslessly when round-tripping.

  • Agent editing with human review. Review attributed agent edits through tracked changes, inline diffs, and before-and-after previews. Accept or reject changes directly in the editor.

  • Real-time collaboration. People and agents edit the same file together, with live cursors and selections. Concurrent changes merge automatically, and offline edits sync when peers reconnect.

  • Undo and redo. Navigate editing history and undo accepted agent proposals as a single step. DOCX hosts can place explicit undo boundaries and choose automatic typing coalescence or manual grouping across multiple edits.

  • Embed or automate. Drop React editors into your app, build on the framework-free JavaScript cores, or use Rust and Python APIs for headless processing and agent workflows.

  • Host-controlled PPTX editing. PPTX hosts can intercept saving, flush accepted input, query slide content under the pointer, group undo with explicit boundaries, and reposition comments.

  • Open source and self-hostable. Apache-2.0 licensed, with control over your document storage, deployment, and collaboration infrastructure.

  • Host-controlled DOCX saving. Intercept Save before export and await pending editor input before reading, changing, or persisting the document.

Try it out, or explore the docs for setup, APIs, and format support.

Packages

Documents — .docx

package registry what it does
betteroffice-docx crates.io typed Rust API for opening, editing, laying out, and saving DOCX documents
@betteroffice/docx npm framework-free .docx editor core — parsing, CRDT editing, and page layout in Rust through WebAssembly
@betteroffice/docx-react npm drop-in React .docx editor
betteroffice-docx PyPI Python API for reading, editing, laying out, and rasterizing DOCX documents

Spreadsheets — .xlsx

package registry what it does
betteroffice-xlsx crates.io typed Rust API for opening, editing, calculating, rendering, and saving XLSX workbooks
@betteroffice/xlsx npm framework-free spreadsheet core powered by the Rust engine through WebAssembly
@betteroffice/xlsx-react npm drop-in React spreadsheet editor
betteroffice-xlsx PyPI Python API for opening, recalculating, styling, rendering, and saving XLSX workbooks

Presentations — .pptx

package registry what it does
betteroffice-pptx crates.io typed Rust API for opening, editing, rendering, and saving PPTX presentations
@betteroffice/pptx npm framework-free .pptx editor core — slide model, masters, image insertion, shape ordering, and rendering in Rust through WebAssembly
@betteroffice/pptx-react npm drop-in React .pptx editor
betteroffice-pptx PyPI Python API for reading, editing, saving, and laying out PPTX presentations

Diagrams (.vsdx, source preview)

VSDX support is available from source and is not yet published.

What to install for which language, with a first example each: npm, crates.io, PyPI.

Benchmarks

Generated by the Benchmarks action.

DOCX

Page agreement is reported on its own because a document either paginates as Word does or it does not; SSIM cannot express that.

BetterOffice (0.2.1)BetterOffice (e8ce123f)LibreOffice (26.2.3.2)
Exact page counts48/6363/6345/63
Absolute page error32056
SSIM0.75400.83680.7749
Scored/total63/6363/6363/63
Render time (avg)546 ms527 ms788 ms
Parse success100.00%100.00%100.00%

PPTX

BetterOffice (0.1.1)BetterOffice (e8ce123f)LibreOffice (26.2.3.2)
SSIM0.86670.89240.9043
Scored/total88/103103/103103/103
Render time (avg)205 ms144 ms1310 ms
Parse success100.00%100.00%100.00%

XLSX

BetterOffice (0.2.1)BetterOffice (e8ce123f)LibreOffice (26.2.3.2)
SSIM0.70020.76600.6901
Scored/total205/208207/208204/208
Recalc accuracy68.28%99.60%85.87%
Recalc time (avg)70 ms89 ms466 ms
Parse success99.52%100.00%100.00%

For scoring, timing, coverage, and limitations, see the benchmark methodology.

Structure

  • crates/ — the Rust engines
  • packages/ — the TypeScript editor packages
  • bindings/ — the Python bindings
  • e2e/ — browser tests, corpus scenarios, and the shared test harness
  • apps/web — betteroffice.dev (Next.js on Cloudflare Workers)
  • apps/demo — editor playground
  • apps/docs — documentation

Development

bun install
bun run dev:demo     # editor playground; builds the wasm bundles on first run
bun run dev          # betteroffice.dev site (no wasm needed)
bun run dev:docs     # documentation site
bun run rust:check   # fmt + clippy + tests for the engines

Run bun run test:e2e:browser for headless browser tests of all three editors. The E2E guide also covers pinned corpus scenarios, cross-SDK checks, and operation profiles. The XLSX and PPTX JavaScript cores expose opt-in operation timings; the native XLSX facade also reports edit stage timings.

Use the Office visual quality harness to export Word, PowerPoint, and Excel references, compare local renders, or refresh the fidelity scores with the manual action.

Contributing

Contributions are welcome. We ask for a one-time signature of the Contributor License Agreement on your first pull request (corporate version).

License

Apache-2.0 — third-party attribution in THIRD-PARTY-NOTICES.md.

About

Native OOXML engines in Rust - DOCX, XLSX & PPTX editing, rendering and real-time collaboration, compiled to WASM for the web.

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages