Skip to content
Switch branches/tags


Failed to load latest commit information.
Latest commit message
Commit time

A simple Pythonic interface for libFLAC.

FLAC stands for Free Lossless Audio Codec, an audio format similar to MP3, but lossless, meaning that audio is compressed in FLAC without any loss in quality. This is similar to how Zip works, except with FLAC you will get much better compression because it is designed specifically for audio.

pyFLAC allows you to encode and decode raw audio data directly to/from a file, or in real-time using callbacks.


You can use pip to download and install the latest release with a single command.

pip3 install pyflac


pyFLAC depends on libsndfile, which requires an extra install step on Linux distributions. See the SoundFile documentation for more information.

Supported platforms

  • macOS
  • Linux
  • RPi Zero/2/3/4
  • Windows 7/8/10


pyFLAC comes bundled with a command line tool to quickly convert between WAV and FLAC files. For more information, print the help info.

pyflac --help


If you didn't install pyFLAC globally then the command line tool will not be installed on your PATH. However you should still be able to access the tool with python3 -m pyflac.