Piwigo API: unlock the full potential of your photo library

Discover how the Piwigo API allows you to automate workflows, connect your tools, and use Piwigo as a reliable image and video management backend for third-party digital platforms.

What is the Piwigo API?

The Piwigo API is an interface that lets you interact programmatically with your photo library, without using the web administration interface. It provides access to most of Piwigo’s features: uploading files, creating or editing albums, managing tags and users, or deleting content.

The API documentation is available on GitHub. To make things easier, Piwigo also provides a visual interface that lets you test each API method directly on your own data.

Piwigo API

To access it, simply go to: [yourpiwigo.com]/tools/ws.htm – first replace [yourpiwigo.com] with your own Piwigo URL.

An API available to all users

Whether you have subscribed to a Piwigo Cloud plan or are running Piwigo in a self-hosted environment, the API is available at no extra cost.

  • Piwigo Cloud customers: the API is included in your subscription, with no request limits.
  • Self-hosted users: since Piwigo is open source, the API is a core part of the software and remains fully accessible.

Unlike many digital asset management solutions, Piwigo does not charge API usage based on the number of requests.

Why use the Piwigo API?

The API allows you to go beyond standard usage of Piwigo. Common use cases include:

  • Automating repetitive tasks: automatically importing large volumes of images or updating metadata.
  • Connecting Piwigo to internal tools: ERP, CMS, PIM, websites, intranets, or business applications.
  • Using Piwigo as an image and video backend for another platform: in this setup, the Piwigo administration interface is rarely used, as all operations are handled via the API.

Real-world API use cases

Some organizations use Piwigo as a digital asset manager that is fully or partially driven by API calls.

EarthScope / UNAVCO

EarthScope / UNAVCO manages an international network of geophysical stations (GPS / GNSS) used to monitor movements of the Earth’s crust. On their website, stations are displayed on an interactive map with detailed information. Each station page includes a photo tab powered by the Piwigo API.

  • Field photos are uploaded to and organized in Piwigo.
  • The front-end queries the API to retrieve images associated with each geolocated station.
  • Each station page displays its related photos dynamically via the API.
  • Behind the scenes, the system handles a high volume of API requests.

Akena Véranda

Akena Véranda (a manufacturer of verandas and aluminium structures) relies on an internal user management system. Their goal was to provide seamless, secure access to the Piwigo photo library from their internal portal, fully synchronized with their corporate directory.

  • A background service synchronizes users from the internal directory with Piwigo via the API (creation, updates, deletion).
  • When a user accesses the photo library from the internal portal, an API call generates a dedicated access key or token, matching the user to their Piwigo account (a custom, in-house SSO system).

ZF

ZF is an automotive parts manufacturer with strong requirements for quality control and traceability. During production runs, an image sample (for example, 12 parts out of thousands) is photographed from all angles. These images must be easy to identify, organize, and retrieve if an issue is detected later.

  • Automated scripts handle the entire workflow via the API: generating tags (lot number, date, orientation), associating tags with images, and uploading photos to the correct albums.
  • If an incident occurs, all images related to a specific production batch can be quickly retrieved using tag-based or date-based searches.

Piwigo as a digital asset management API

The Piwigo API enables advanced use cases similar to those offered by proprietary Digital Asset Management (DAM) solutions. In practice, your Piwigo library can become:

  • a centralized engine for managing images and videos,
  • an automated content source for websites or e-commerce platforms,
  • a connected media library integrated into your business applications.

In English-language contexts, Piwigo can also be described as a photo management API or a digital asset management API.

With two key advantages:

  1. Open source: the codebase is open and documented, with no vendor lock-in.
  2. Unlimited and included API access: no hidden fees and no usage-based pricing.

Conclusion

The Piwigo API is a powerful tool for automating workflows, connecting systems, and integrating your photo library into your own digital ecosystem. Whether you use it simply to import files from external sources or as a full-scale backend managing millions of images, the API is included with Piwigo, with no additional cost or limits.

👉 To learn more and start testing the API, visit the official documentation.

Expiry Date : a new plugin to manage expiration dates on photos

How to manage the expiration date of image usage rights and photo consents on your photo library? With the Expiry Date plugin for Piwigo, it’s easy. Today, let’s discover this new plugin designed in collaboration with one of our Enterprise customers.

Expiry Date : presentation

Expiry Date is a new plugin for our enterprise customers. It is not available by default on your Piwigo: you have to contact the customer support to benefit from it as part of your subscription (if you have an enterprise account).

Once activated on your gallery, this plugin will add a new “Expiry Date” field available on each photo.

You can change the expiry date of a photo from Piwigo’s administration, either individually or in bulk on a selection of photos with the batch manager.

Add an expiry date to a selection with the batch manager

Once an expiry date has been set on a photo, it will appear next to the other fields in your gallery.

Display of the expiry date on the gallery

The plugin’s settings allow you to choose what happens when the expiry date is reached.

You can choose between 3 options :

  • doing nothing (the date is just informative)
  • deleting the photos
  • archiving the photos (i.e. move them to a private album of your choice)

In addition, you can send an email notification before the date and on the precise day of the expiry date:

  • to users who downloaded the file (if visit history is enabled)
  • to your gallery administrators.

Why should you use the Expiry Date plugin?

There are several cases where you need to manage an expiration date or expiry date on a photo or any other file.

Information

Expiry date or expiration date? Well, both terms are OK. Expiry date is most often used in British English, and expiration date is more frequent in American English.

Image usage rights / copyright

First of all, it is necessary when the image usage rights are limited in time and must be renewed. 

This is often the case when you buy photos from a photographer, or on an online image bank: the license can be limited to 5 years or less. 

If you are still using an image on your website or in any communication medium when your license has expired, you may be prosecuted for copyright violation.

Photo consent policy

Then, there is the case of photo consent: in some cases and some countries, if you want to use a photo or a video of a physical person on your website or any other medium, you must first obtain their consent. The contract can mention a maximum duration, at the end of which you no longer have the right to use this image. 

These two legal constraints are the main reasons why an expiration date (or expiry date) can be useful on a photo, but there are many other use cases.

Are you interested in this plugin? Contact the support at the usual email address to request it! 

Warning

Any request made in the comment section on the blog will not be treated.  But feel free to tell us in comments what you could use this plugin for!


For more information on copyright and image rights, you can read the articles below. 

Please keep in mind that rules can differ depending on your country.

Copyright and GDPR for photographers (UK)

The Ultimate Guide To Photo Release Forms

Image Usage Rights 101: How to Make Sure You’re Covered

Legally using images

How to organize team work with Piwigo?

Over the years, Piwigo has integrated many features that allow you to collaborate with your team or partners, in an efficient and secure way. However, some of these features are still unknown to our customers! That’s why we have decided to focus on user management in this article.

Read More

Add a filter bar to your photo gallery

You want to offer your visitors an user friendly interface to navigate through your photo gallery? With the Tag Groups plugin, you can add multiple filters to your Piwigo photo library.

Warning

This plugin is not available to customers who have subscribed to an “Individual” offer on piwigo.com.

Reminder: how tags work with Piwigo

If your Piwigo photo library contains a lot of media, you’ve probably decided to organize them with tags, or keywords.

Tags allow you to qualify your photos according to your own classification criteria: this can be colors, image formats, places, themes or any other useful information to easily find photos that have something in common.

A photo can have an infinite number of tags, and you can combine tags to refine your search.

The tag search is available from the “Related tags” menu item of your photo library (that you can activate with the “Menu Tags” plugin), or from a tag cloud that can be displayed on a page of your gallery.

tag cloud piwigo

Example of tag cloud

Thus, the tags are complementary to the albums.

Let’s take the example of the photo library of the Archeological Museum Archéa.

The photos of this photo library are organized in albums: Exhibitions, Collections… Each album is also organized in sub-albums: in the Exhibitions album, there is one sub-album per exhibition.

But if you’re looking for photos that match a finer criterion, that’s where the tags will prove themselves useful. You can find in one click all the photos tagged “Middle-Ages”, “Necropolis”, or “Merovingians”, whatever their album.

What if I want all the pictures of Merovingian necropolises?

Don’t worry: I just have to combine the two tags “Necropolis”, and “Merovingian”, as you can see on the example below.

search multi tags piwigo

This operation is very simple and convenient, but the tags are all mixed together. 

For an even better organisation, and an easier search, a new plugin is available on your Piwigo photo library.

Set up a filtering search bar with The Tag Groups plugin

This plugin allows you to use tags to set up a filtering search bar on your photo gallery.

How does it work?

You now have the ability to regroup the tags by family, with the new notion of “tag group”. 

The tags “blue”, “pink”, “green” can be associated with a “color” group. To do this, simply add a prefix in the tag name. Thus, by naming a tag “color:blue”, you will have the tag “blue” belonging to the “color” group.

You can see below a page that lists the tags of a Piwigo gallery, grouped by tag group.

word cloud tags piwigo

If we go on with the Archéa Museum example, we could imagine that the tags “High Middle Ages”, “Classical Middle Ages”, “Gallo-Roman Antiquity” and “Merovingian” would be classified in the “Period” group.

And the tags “ceramics”, “ornaments”, “furniture”, “tools”, “religious practices” etc. could be classified in the “Objects” group.

We could thus set up in the gallery a search engine with filters by period, and by type of object, with drop-down lists as in the example below.

tag groups plugin piwigo
Photo library on which the Tag Groups plugin has been installed

On the above example, (click on the image to enlarge it if necessary), you can see that we first filtered the pictures to show only the “Tulip” type flowers.

You can then refine the selection by color with the “Color” filter. It lists all tags of type “Color”, but only those that are present on photos that also have the tag “Tulip” are clickable.

filter bar multi criteria piwigo

If I select the “Purple” color, the selection only shows me files with the “Tulip” tag AND the “Purple” tag.

filter bar multi criteria piwigo

If you wish to test by yourself, you can view a demo by clicking on this link.

We hope you like this new feature!  Would you like to implement it on your Piwigo gallery?

If so, you have two options :

  • If you host your Piwigo yourself, download the Tag Groups plugin
  • If you are a customer of a hosting offer with Piwigo.com, please contact support. Indeed, you can’t (yet) activate the Tag Groups plugin yourself. Warning! This plugin is only available for customers who subscribed to an Enterprise offer.

Where are photos stored with Piwigo ?

Looking for an online solution to manage your photo library, someone recommended Piwigo, but you don’t really understand how it works, and where your photos will be hosted? Don’t worry, you will find everything you need to know in this blog post!

Piwigo.org or Piwigo.com ?

Firstly, you will need to understand the difference between the two options available, this difference could be confusing for some :

  • On the one hand you can download the open source Piwigo software on piwigo.org;
  • Or on the other you can create an account on piwigo.com.

1 – You host Piwigo by yourself

If you choose the first option, you will download files for free from piwigo.org, which you will have to install on a server. You will have to subscribe to an offer from a web hosting service and deploy your Piwigo yourself before you can upload your photos and organize them.

Manual installation of Piwigo

In this case, your photos will be stored on the server that hosts the application. Thus, if you install Piwigo on a shared hosting, at Gandi for example, your photos will be saved on the storage system associated with this hosting.

To find out more, check with your host to find out exactly where this storage system is located because it can be “remote”.

2 – You choose Piwigo.com

If you choose the second option, and sign up with piwigo.com, your Piwigo library will be created directly on our platform.

Sign up form on Piwigo.com
Sign up form on Piwigo.com

In this case, your library will be hosted on dedicated servers (which means that they are not shared with other sites). Piwigo rents these servers from OVH, a french host. Our servers are located in France at the Roubaix, Strasbourg and Gravelines data centers. Your data is stored on the hard drives of these servers, i.e. exactly where the Piwigo app runs.

To answer the question many users might ask, especially public administrations, we do not use the services of Amazon (AWS), Google (Cloud Platform) or Microsoft (Azure). We do not use them for two main reasons:

  • Firstly, we do not want to entrust them with our customers’ data;
  • Secondly, these services are very expensive, which would in all logic increase the price of our offers.

What guarantees for you data safety ?

If you choose to host your Piwigo yourself, it is up to you to make sure that your hosting provider has done what it takes to ensure that your data is safe. You are also solely responsible for backing up your data and files.

But if you choose one of our offers on Piwigo.com, we take care of everything: let’s see how we ensure that your data will not be lost.

Piwigo.com’s technical infrastructure is based on coupled servers. Each “main” server is duplicated by a “secondary” server that serves as backup system.

A Piwigo.com account is hosted on a main server (photos and database). Every night, each main server is synchronized to its secondary server. And every night, we make a copy of each database, and we keep at least the last 30 days. This allows us to restore your photo library in case of handling errors. To make it simple, we can restore an album that you deleted by mistake.

backup server
Every night, each main server is synchronized to its secondary server.

In addition to night-time synchronization, we have set up a backup system with finer granularity. Every 15 minutes, a script checks if there have been any changes on your Piwigo: add/edit/delete photo/album/tag/user/comment.

If any change is detected, your account is automatically synchronized on the secondary server. All these mechanics allow us, in the worst case scenario, to lose only the last 15 minutes of activity.

What if I want to switch hosting ?

One of Piwigo.com’s promises is to fight against “customer lockdown”.

We definitely don’t want to put a brake on you the day you want to switch to another hosting, or even to your own infrastructure. If you host your data on Piwigo.com, you can download your database and files at any time. You can move your Piwigo on to your own server if you wish, keeping your photo library exactly the same.

You will not lose the many hours spent organizing your content, visit history or user comments. All these operations are documented, just follow the guide!

But you can also decide to move your Piwigo from your server to Piwigo.com. We regularly carry out this operation for our customers. We take care of everything: data transfer, database import, Piwigo updates and extensions. This transaction is not billed as we consider it to be part of the services associated with the Piwigo.com offer.

To sum things up :

Piwigo offers two different ways to use its photo library management software and therefore, two different ways to store your files:

  • On the server of your choice if you choose the free download on piwigo.org
  • On our dedicated servers if you choose one of our piwigo.com offers.

Both solutions are used by thousands of individuals and professionals, and might fit your needs. It is up to you to decide which one is best for you!

Piwigo.com technical infrastructure

Today we publish a new page on Piwigo.com presentation website: Infrastructure. You will learn where and how your photos are hosted. You will also learn which measures we have implemented to make Piwigo.com a safe place for your photos.

Piwigo.com technical infrastructure, where and how are your photos stored?

Piwigo.com technical infrastructure, where and how are your photos stored?

Special thanks to Tadjio for correcting the page.

Feel free to ask questions if you want to learn more about our infrastructure.

Robots and visit history

Piwigo 2.6 has introduced a geolocation feature for your visitors. Now you know where your visitors come from and you may have discovered that you often receive visits from Redmond (Washington, USA)  and Mountain View (California, USA). Don’t panic, this is not an attack: they are just robots of Bing (Microsoft search engine) and Google.

Visit history, Bing is visiting your Piwigo (Redmond, USA)

Visit history, Bing is visiting your Piwigo (Redmond, USA)

Their visits are useful because they make you “findable” in search engines. But maybe you don’t want to see all this noise in your visit history. Activate the new plugin No Stats for Robots if you want to see only real human visitors. Of course, this plugin won’t stop search engines, it just avoid registering their visits.