Most unix-like operating systems have libvips packages, check your package manager. For macOS, there are packages in Homebrew, MacPorts and Fink. For Windows, there are pre-compiled binaries in the Download area.
Installing on macOS with homebrew
Install homebrew, then enter:
brew install vips
That will install vips with most optional add-ons included.
Installing the Windows binary
vips-dev-w64-web-x.y.z.zip from the Download area and unzip somewhere. At the command-prompt,
vips-x.y.z/bin and run (for example):
vips.exe invert some/input/file.jpg some/output/file.jpg
If you want to run
vips.exe from some other directory on your PC,
you’ll need to set your
The zipfile includes all the libraries and headers for developing with C with
any compiler. For C++, you must build with
g++, or rebuild the C++ API
with your compiler, or just use the C API.
vips-dev-w64-web-x.y.z.zip is built with a small set of relatively secure
file format readers and can be used in a potentially hostile environment. The
vips-dev-w64-all-x.y.z.zip includes all the file format readers
that libvips supports and care should be taken before public deployment.
The Windows binary is built
by build-win64. This is a
containerised mingw build system: on any host, install Docker,
clone the project, and type
./build.sh 8.5. The README has notes.
Building libvips from a source tarball
If the packaged version is too old, you might need to build from source.
vips-x.y.z.tar.gz from the Download area, then:
tar xf vips-x.y.z.tar.gz cd vips-x.y.z ./configure
Check the summary at the end of
configure carefully. libvips must have
You’ll need the dev packages for the file format support you want. For basic
jpeg and tiff support, you’ll need
libgsf-1-dev. See the Dependencies section below for a full list
of the things that libvips can be configured to use.
configure is looking OK, compile and install with the usual:
make sudo make install sudo ldconfig
By default this will install files to
We have detailed guides on the wiki for building for Windows and building for macOS.
Building libvips from git
Checkout the latest sources with:
git clone git://github.com/jcupitt/libvips.git
Building from git needs more packages, you’ll need at least
gobject-introspection, see the dependencies section below.
./autogen.sh make sudo make install
And perhaps also:
libvips has to have
expat. Other dependencies are
optional, see below.
If suitable versions are found, libvips will add support for the following
libraries automatically. See
./configure --help for a set of flags to
control library detection. Packages are generally found with
so make sure that is working.
Libraries like giflib do not usually use
pkg-config so libvips looks for
them in the default path and in
$prefix. If you have installed your own
versions of these libraries in a different location, libvips will not see
them. Use switches to libvips configure like:
./configure --prefix=/Users/john/vips \ --with-giflib-includes=/opt/local/include \ --with-giflib-libraries=/opt/local/lib
The IJG JPEG library. Use the
-turbo version if you can.
If available, libvips adds support for EXIF metadata in JPEG files.
The standard gif loader. If this is not present, vips will try to load gifs via imagemagick instead.
The usual SVG loader. If this is not present, vips will try to load SVGs via imagemagick instead.
If present, libvips will attempt to load PDFs via PDFium. This library must be packaged by https://github.com/jcupitt/docker-builds/tree/master/pdfium
If PDFium is not detected, libvips will look for poppler-glib instead.
The Poppler PDF renderer, with a glib API. If this is not present, vips will try to load PDFs via imagemagick.
If available, libvips adds support for creating image pyramids with
The TIFF library. It needs to be built with support for JPEG and ZIP compression. 3.4b037 and later are known to be OK.
If libvips finds this library, it uses it for fourier transforms.
are available for transforming images with ICC profiles.
If present, libvips can load and save png files.
If present, libvips can write 8-bit palette-ised PNGs.
ImageMagick, or optionally GraphicsMagick
If available, libvips adds support for loading all libMagick-supported
image file types. Use
--with-magickpackage=GraphicsMagick to build against
Imagemagick 6.9+ needs to have been built with
--with-modules. Most packaged
IMs are, I think.
If you are going to be using libvips with untrusted images, perhaps in a web server, for example, you should consider the security implications of enabling a package with such a large attack surface.
If available, libvips adds support for text rendering. You need the
package pangoft2 in
If available, vips will accelerate some operations with this run-time compiler.
If available, vips can load images from Matlab save files.
If available, vips can load FITS images.
If available, vips can load and save WebP images.
If available, vips can load and save NIFTI images.
If available, libvips will directly read (but not write, sadly) OpenEXR images.
If available, libvips can load OpenSlide-supported virtual slide files: Aperio, Hamamatsu, Leica, MIRAX, Sakura, Trestle, and Ventana.
If available, libvips can load and save HEIC images.