---
title: "Using Rest PKI on Python"
description: "Using Rest PKI on Python with the restpki-client PyPI package, which supports Python 2 and 3, starting from the Python Flask samples project."
canonical: "https://docs.lacunasoftware.com/en-us/articles/rest-pki/python"
locale: "en"
product: "Rest PKI (legacy)"
last_updated: "2026-10-12"
---

# Using Rest PKI on Python

Rest PKI can be used on Python. To get started, see the [Python/Flask samples project](https://docs.lacunasoftware.com/en-us/articles/rest-pki/python/flask).

## Client library

The Python/Flask sample project uses the PyPI package [restpki-client](https://pypi.org/project/restpki-client/) to access Rest PKI on Python applications. It supports Python 2 and Python 3.

To add it to your project, add the line below to your `requirements.txt` file:

```text
restpki-client==1.3.1
```

After that, do a `pip install -r requirements.txt` to download the package and its dependencies.

> If you don't have **pip** installed, get it [here](https://pip.pypa.io/en/stable/installing/)

### Source code

The package is open-source, hosted on [GitHub](https://github.com/LacunaSoftware/RestPkiPythonClient). Feel free to fork the package if you need to make any customizations.
