Zero-config: drop documents in a folder, point the CLI at it, open the browser.
pip install groupdocs-viewer-net-ui
mkdir docs
cp ~/Documents/*.docx ~/Documents/*.pdf docs/
groupdocs-viewer-ui serve --files ./docs --cache ./.viewer-cache
# → SPA at http://127.0.0.1:8080/viewer/serve wires up:
LocalFileStoragerooted at--filesLocalFileCacheat--cache(omit the flag to disable caching)SelfHostViewerwrappinggroupdocs-viewer-net- A
uvicornprocess serving the resulting ASGI app
| Flag | Default | What it does |
|---|---|---|
--files DIR |
cwd | Document root |
--cache DIR |
(disabled) | Where to persist rendered pages between runs |
--port N |
8080 | HTTP port |
--host H |
127.0.0.1 | Bind address |
--rendering-mode html|image |
html | HTML preserves text/search; image is a screenshot |
When you need authentication, custom storage, or to embed the viewer in
an existing web app, switch from the CLI to create_app(...) directly —
see examples/02_fastapi_basic/.