Skip to main content

Pure Python, cross platform, single function module with no dependencies for playing sounds.

Project description

Pure Python, cross platform, single function module with no dependencies for playing sounds.


Install via pip:

$ pip install playsound


If you insist on the (slightly) harder way of installing, from source, you know how to do it already and don’t need my help.

This library might be uploaded to github at some point at

Quick Start

Once you’ve installed, you can really quickly verified that it works with just this:

>>> from playsound import playsound
>>> playsound('/path/to/a/sound/file/you/want/to/play.wav')


The playsound module contains only one thing - the function (also named) playsound.

It requires one argument - the path to the file with the sound you’d like to play.

WAVE files should definitely work on all platforms. MP3 is known to work on OS X. Other format/platform combos may also work.

Relies on winsound.PlaySound on Windows, AppKit.NSSound on OS X, and ossaudiodev on Linux.

There’s an optional second argument, block, which is set to True by default. Setting it to False does what you’d expect on OS X and Windows. It does nothing on Linux.


playsound should work on any version of OS X, Windows, or Linux, and any version of Python since 2.3. So basically there are no requirements.

Admittedly, I haven’t tested it on particularly old versions of Python or OS X, and I haven’t tested it on Linux at all, but it should just work everywhere.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for playsound, version 1.0.0
Filename, size File type Python version Upload date Hashes
Filename, size playsound-1.0.0.tar.gz (3.5 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page