# OfficeCLI

> Command-line tool that lets AI agents create and edit Word, Excel and PowerPoint files

- Repository: https://github.com/iOfficeAI/OfficeCLI
- Category: Agent skills & plugins
- Stars: 32,336 · Forks: 2,203 · Language: C# · License: Apache-2.0
- Experience: Some experience
- Page: https://ir.adyog.com/repos/iofficeai/officecli/

AI agents often need to produce Office documents, but the usual route is a Python library such as python-pptx and many lines of code per slide. OfficeCLI replaces that with short shell commands, for example adding a slide with one `officecli add` call. It is written in C#, ships as one binary, and needs no Office install.

Every element in a document has a path, such as /slide[1]/shape[1]. You work on those paths with commands like create, add, set, get, remove and view, and you can get plain text or JSON back. A live preview (`officecli watch`) opens in your browser and refreshes after each command.

The README says its built-in renderer turns documents into HTML or PNG, so an agent can render, look at the result and fix it. An install command also adds a skill file to coding agents it detects, including Claude Code, Cursor, Windsurf and GitHub Copilot. For people who prefer a desktop app, the README points to AionUi, which is built on it.

## What it does

- **Three formats, read and write**: Reads, modifies and creates Word, Excel and PowerPoint files, with output as plain text or structured JSON.
- **Wide element support**: Covers tables, charts, images, equations and tracked changes in Word; formulas, pivot tables and conditional formatting in Excel; animations, transitions and themes in PowerPoint.
- **Rendering and live preview**: Converts documents to HTML or PNG, and `officecli watch` serves a browser preview that updates with each command.
- **Agent skill install**: `officecli install` copies the binary onto your PATH and installs a skill into the AI coding agents it detects.
- **No Office needed**: Runs as a single binary with no dependencies. Install options include a shell script, Homebrew and npm.

## What you could build

- Let a coding agent generate a slide deck from a prompt and check how it looks.
- Build an Excel budget tracker or gradebook with formulas and charts from a script.
- Draft a Word report with headings, tables, a table of contents and comments.
- Audit existing documents for formatting problems or inconsistent styles.
- Run batch edits across many Office files on a server with no Office installed.

## Who it's for

Suits developers and agent users who want AI to produce or edit Office files; you should be comfortable running shell commands.

## Get started

Install the binary with the script (or Homebrew or npm), then create a blank deck and start the live preview. In a second terminal, add a slide and watch the browser update. To give your agent the skill, download the binary from GitHub Releases and run `officecli install`.

```
curl -fsSL https://raw.githubusercontent.com/iOfficeAI/OfficeCLI/main/install.sh | bash
```
```
officecli create deck.pptx
```
```
officecli watch deck.pptx
```

Tags: office, cli, docx, pptx, xlsx
