---
title: "Convert documents and images to PDF locally"
description: "\"Convert these three scanned JPEGs into a single PDF, and also turn this Word document into a PDF — all without uploading anything to an external service.\""
canonical: "https://hub.ironclaw.com/usecases/convert-documents-and-images-to-pdf-locally"
markdown: "https://hub.ironclaw.com/usecases/convert-documents-and-images-to-pdf-locally.md"
type: "use-case"
categories: ["Personal assistant","Files / knowledge"]
author: "mr.potato"
---

# Convert documents and images to PDF locally

## Example Prompt

> "Convert these three scanned JPEGs into a single PDF, and also turn this Word document into a PDF — all without uploading anything to an external service."

## What the Agent Does

Uses Stirling PDF's local API to convert images (JPG, PNG, TIFF, WebP) and documents (Word, PowerPoint, HTML, and more) into PDFs entirely on your own machine. No file ever leaves your system — Stirling PDF runs as a self-hosted Docker container or desktop app and exposes a REST API that the agent calls directly.

The agent handles single files or batches, and can chain conversions into further PDF operations: merge pages, compress output, add page numbers, or apply OCR. This makes it the go-to approach for converting sensitive documents (contracts, medical records, ID scans) that you'd normally have to upload to an online converter.

Run Stirling PDF locally in one command:
```
docker run -p 8080:8080 docker.stirlingpdf.com/stirlingtools/stirling-pdf
```
Then ask the agent to convert any file — it will call the local API at `http://localhost:8080`.

## Skills and Tools

- Stirling PDF (local REST API)
- File read/write

## Categories

- Personal assistant
- Files / knowledge

## Links

- [HTML page](https://hub.ironclaw.com/usecases/convert-documents-and-images-to-pdf-locally)
- [Source](https://github.com/Stirling-Tools/Stirling-PDF)

