# Install jpegoptim with Homebrew, apk, apt, dnf, MacPorts, Nix, pacman, zypper, scoop, winget

Utility to optimize JPEG files. Version 1.5.6 via Homebrew; verified 2026-07-29. Also installable with debian: sudo apt install jpegoptim.

## Install

```sh
sudo av install brew:jpegoptim
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install jpegoptim
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install jpegoptim
```

  Evidence: MacPorts ports tree: graphics/jpegoptim/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add jpegoptim
```

  Evidence: Alpine Linux edge package indexes: jpegoptim from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install jpegoptim
```

  Evidence: Debian stable package indexes: jpegoptim from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install jpegoptim
```

  Evidence: Fedora Rawhide package metadata: jpegoptim from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#jpegoptim
```

  Evidence: nixpkgs package indexes: pkgs/by-name/jp/jpegoptim/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S jpegoptim
```

  Evidence: Arch Linux sync databases: jpegoptim from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install jpegoptim
```

  Evidence: openSUSE Tumbleweed package metadata: jpegoptim from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

### Windows

- Scoop (92%):

```sh
scoop install main/jpegoptim
```

  Evidence: Scoop official bucket manifest trees: bucket/jpegoptim.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

- winget (92%):

```sh
winget install --id TimoKokkonen.Jpegoptim -e
```

  Evidence: Windows Package Manager source index: TimoKokkonen.Jpegoptim from https://cdn.winget.microsoft.com/cache/source.msix

## Package facts

- **Package key:** brew:jpegoptim
- **Package manager:** Homebrew
- **Version:** 1.5.6
- **Source summary:** Utility to optimize JPEG files
- **Homepage:** <https://github.com/tjko/jpegoptim>
- **Repository:** <https://github.com/tjko/jpegoptim>
- **Last updated:** 2026-07-29T14:13:06+09:00
- **Generated:** 2026-08-03T19:37:03+00:00

## Executables

- jpegoptim (alias)

## Install behavior

- Bottle: not available

## Freshness

- Page generated: 2026-08-03
- Package-manager version: 1.5.6
## Project history and usage

jpegoptim is Timo Kokkonen's long-running command-line optimizer for JPEG/JFIF files. It focuses on lossless Huffman-table optimization and optional lossy recompression controlled by quality or target-size flags.

### Project history

The upstream README records copyright years beginning in 1996 and lists v1.0 as the first public release. The project was built around IJG libjpeg, with compatibility notes for libjpeg-turbo and mozjpeg, and it stayed close to the Unix tradition of a small binary that rewrites files in place unless directed otherwise.

The 1.2 and 1.3 series added metadata preservation and stripping controls, GNU autoconf support, progressive JPEG support, target-size compression, and better cross-platform handling. The 1.4 and 1.5 series added stdin/stdout workflows, parallel workers, safer marker handling, fuzzing integration, CI-built binaries, and options such as `--retry`, `--save-extra`, and `--auto-mode`.

### Adoption history

jpegoptim became a standard packaging target because web developers, image pipelines, and static-site build scripts needed a scriptable way to reduce JPEG size without changing formats. Its presence across Homebrew, Debian, Fedora, MacPorts, Nix, Arch, Scoop, Ubuntu, winget, and openSUSE reflects broad use in both Unix and cross-platform developer environments.

### How it is used

The tool is commonly run over directories of JPEGs to reduce file size, strip or preserve metadata, convert progressive mode, or cap quality. Because it can preserve modification times and permissions and can emit CSV progress, it fits automation as well as one-off cleanup.

### Why package nerds care

jpegoptim is notable because it turns a libjpeg-compatible encoder into a packaging-era workhorse: tiny CLI surface, old-school C portability, and enough knobs for web-performance pipelines. It also shows the practical boundary between lossless JPEG optimization and deliberate lossy recompression.

### Timeline

- 1996: Copyright period begins in the upstream README.
- v1.0: First public release, as listed in the upstream history.
- v1.3.0: Added progressive JPEG support and target-size lossy optimization.
- 2022-09-15: v1.5.0 added `--workers` for parallel processing.
- 2025-09-15: v1.5.6 added `--retry`, `--save-extra`, `--auto-mode`, initial unit tests, and OSSFuzz integration.

### Related projects

- Related projects include IJG libjpeg, libjpeg-turbo, mozjpeg, jpeginfo, imageoptim-style GUI tools, and web image build pipelines.

### Sources

- <https://github.com/tjko/jpegoptim>
- <https://github.com/tjko/jpegoptim/releases>
- <https://raw.githubusercontent.com/tjko/jpegoptim/master/README>
- <https://raw.githubusercontent.com/tjko/jpegoptim/master/jpegoptim.1>
- <https://www.kokkonen.net/tjko/projects.html>


## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals

## Other Package-Manager Records

- Debian apt - jpegoptim - 1.4.7-1: normalized package name match | Debian stable package indexes: jpegoptim from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | utility to optimize jpeg files | http://www.kokkonen.net/tjko/projects.html
- Nix - jpegoptim: normalized package name match | nixpkgs package indexes: pkgs/by-name/jp/jpegoptim/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - jpegoptim - 1.4.7-1: normalized package name match | Ubuntu 24.04 LTS package indexes: jpegoptim from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | utility to optimize jpeg files | http://www.kokkonen.net/tjko/projects.html
- apk - jpegoptim - 1.5.6-r1: normalized package name match | Alpine Linux edge package indexes: jpegoptim from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | JPEG optimization utility | https://github.com/tjko/jpegoptim
- apk - jpegoptim-doc - 1.5.6-r1: normalized package name match | Alpine Linux edge package indexes: jpegoptim-doc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | JPEG optimization utility (documentation) | https://github.com/tjko/jpegoptim
- dnf - jpegoptim - 1.5.6-3.fc45: normalized package name match | Fedora Rawhide package metadata: jpegoptim from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Utility to optimize JPEG files | http://www.kokkonen.net/tjko/projects.html
- pacman - jpegoptim - 1.5.6-1: normalized package name match | Arch Linux sync databases: jpegoptim from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | Jpeg optimisation utility | https://github.com/tjko/jpegoptim
- zypper - jpegoptim - 1.5.6-1.5: normalized package name match | openSUSE Tumbleweed package metadata: jpegoptim from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Utility for Optimizing JPEG Files | https://www.kokkonen.net/tjko/projects.html
- MacPorts - jpegoptim: normalized package name match | MacPorts ports tree: graphics/jpegoptim/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Scoop - main/jpegoptim: normalized package name match | Scoop official bucket manifest trees: bucket/jpegoptim.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1
- winget - TimoKokkonen.Jpegoptim: normalized package name match | Windows Package Manager source index: TimoKokkonen.Jpegoptim from https://cdn.winget.microsoft.com/cache/source.msix


## Combined YAML source

View the package source record on GitHub. [combined/jpegoptim.yml](https://github.com/mxcl/pkgdb/blob/main/combined/jpegoptim.yml)


## Sources

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
