# OfficeCLI

> Single-binary CLI that lets AI agents create, read, edit, and render Word, Excel, and PowerPoint files without an Office installation.

Stars: 32.7k · Language: C# · License: Apache-2.0 · Categories: AI

- Repository: https://github.com/iOfficeAI/OfficeCLI
- Website: https://officecli.ai
- Page: https://www.trmn.sh/tools/officecli

## Install

- Homebrew: `brew install officecli`
- npm: `npm install -g @officecli/officecli`
- Shell script (macOS / Linux): `curl -fsSL https://raw.githubusercontent.com/iOfficeAI/OfficeCLI/main/install.sh | bash`

## Overview

OfficeCLI is a command-line tool for creating, reading, and modifying .docx, .xlsx, and .pptx files. It ships as a single binary with no dependencies and does not require Microsoft Office. It is aimed at AI agents: running `officecli install` copies the binary to your PATH and installs an "officecli skill" into detected coding agents such as Claude Code, Cursor, Windsurf, and GitHub Copilot.

Commands use a path-based element model. `create deck.pptx` makes a blank file. `add deck.pptx / --type slide --prop title="Q4 Report"` adds content. `get deck.pptx '/slide[1]/shape[1]' --json` returns structured JSON for an element. `view deck.pptx outline` prints a text outline, and `view deck.pptx html` opens a rendered preview. `set` and `remove` modify and delete elements, and `close` flushes the resident session to disk. The README says the tool can also analyze formatting and style problems and move or copy elements across documents.

A built-in HTML rendering engine renders documents to HTML or PNG, so an agent can render, inspect, and fix its output in a loop. `officecli watch deck.pptx` serves a live preview at http://localhost:26315 that refreshes after each add, set, or remove command.

Word support covers i18n and RTL (for example `create --locale ar-SA`), tables, styles, headers and footers, equations with LaTeX input, mermaid diagrams, comments, footnotes, tracked changes with accept and reject, form fields, content controls, and OLE objects. Excel support includes reading formulas and modifying charts. The target users are developers building agent workflows and people who want agents to produce Office documents. The AionUi desktop app is available as a GUI built on OfficeCLI.

### Installation

```bash
# via Homebrew
brew install officecli
```

```bash
# via npm
npm install -g @officecli/officecli
```

```bash
# via Shell script (macOS / Linux)
curl -fsSL https://raw.githubusercontent.com/iOfficeAI/OfficeCLI/main/install.sh | bash
```

![OfficeCLI creating a PowerPoint presentation on AionUi](https://media.trmn.sh/cached/c00b3b77c1e08934ecd3d23933afec2a7763c688eaa44d5ba2875d417ee74a6e.webp)

![OfficeCLI academic paper (Word)](https://media.trmn.sh/cached/8bb31fe4cd27d4eb7665f8ce424b21ea9dc31e6d470116463e5ddb720b14a596.gif)

![OfficeCLI budget tracker (Excel)](https://media.trmn.sh/cached/f59093a644c1c6468ca9901816c2afa0c12ca0060da5e48dd02b7d1f8dc50f2e.gif)

## Alternatives

- [OpenClaude](https://www.trmn.sh/tools/openclaude.md): Open-source terminal coding-agent CLI that works with OpenAI-compatible APIs, Gemini, GitHub Models, Codex, Ollama and other cloud or local model backends. (TypeScript, 34.2k stars)
- [OpenCLI](https://www.trmn.sh/tools/opencli.md): Turns websites and Electron apps into CLI commands and lets AI agents drive your logged-in Chrome via a Browser Bridge extension and opencli browser primitives. (JavaScript, 30.7k stars)
- [DeepSeek-Reasonix](https://www.trmn.sh/tools/deepseek-reasonix.md): Open-source coding agent shipped as a single Go binary with a TUI, desktop app, and ACP editor integration; DeepSeek preset, any OpenAI-compatible model. (Go, 36.0k stars)
- [Continue](https://www.trmn.sh/tools/continue.md): Open-source coding agent distributed as a CLI, VS Code extension, and JetBrains plugin. Repository is read-only after the final 2.0.0 release. (TypeScript, 36.4k stars)
- [Crush](https://www.trmn.sh/tools/crush.md): Terminal-based agentic coding assistant from Charm that connects to many LLM providers, uses LSPs for context, and extends via MCP servers. (Go, 28.9k stars)

---

Canonical: https://www.trmn.sh/tools/officecli
