SoundCard
Play and record audio without resorting to CPython extensions
Decision gist · record as of 2026-08-14
Yes. SoundCard is a solid choice for cross-platform audio I/O in Python. It has low install friction (pure Python, two lightweight dependencies), active maintenance, permissive licensing, no known vulnerabilities, and a clear, documented API. Install it if you need speaker/microphone access without C extension overhead. Be aware that it is a hobby project—response to issues is not guaranteed to be timely—and that latency and device behavior can vary across platforms and hardware.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.5 or later.
- On Linux, PulseAudio or compatible audio system must be available; on macOS, CoreAudio; on Windows, WASAPI.
- Audio data must be normalized between -1 and 1 to avoid clipping.
License · maintenance · safety
BSD 3-clause (permissive) — BSD 3-clause is permissive; you may use, modify, and distribute this package freely in commercial and private projects, provided you include the license notice and disclaimer.
last release 2026-04-12 (124 days) · last repo commit 2026-06-17 · 763 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 126,196 downloads/mo, #11,786 on PyPI
Alternatives
Verify before relying
pip install soundcard
import soundcard as sc
import numpy
# Record one second of audio
default_mic = sc.default_microphone()
data = default_mic.record(samplerate=48000, numframes=48000)
# Play back the recorded audio
default_speaker = sc.default_speaker()
default_speaker.play(data / numpy.max(numpy.abs(data)), samplerate=48000)- Whether latency tuning via blocksize and numframes parameters meets real-time or low-latency application requirements in practice.
- Support status for less common sound cards or multi-channel professional audio interfaces beyond the documented examples.
- Whether the experimental exclusive_mode flag on Windows/WASAPI is production-ready or still carries stability risks.
What it is and what it does
SoundCard is a Python library for audio input and output that wraps the native audio APIs of Linux (PulseAudio), macOS (CoreAudio), and Windows (WASAPI) without requiring compiled C extensions. It exposes a unified interface for discovering, selecting, and controlling speakers and microphones, and handles audio data as NumPy arrays scaled to 0dBFS (Full Scale). The library supports both one-shot recording and playback as well as continuous streaming via Recorder and Player context managers.
The package is designed for developers who need cross-platform audio I/O without the complexity of lower-level audio frameworks or the overhead of CPython extensions. It handles channel mapping, sample rate configuration, and latency tuning through blocksize parameters. The library is actively maintained, supports current Python versions, and carries no known security vulnerabilities, though it remains a hobby project and response times to issues may vary.
Use it for
- Record audio from a microphone and play it back through speakers in real-time or batch mode.
- Build a voice assistant or audio processing pipeline that captures input from a specific microphone by name.
- Stream audio continuously from a multi-channel professional sound card using channel maps.
- Implement low-latency audio applications by tuning blocksize and numframes parameters.
- Discover and enumerate available audio devices on a user's system for dynamic device selection.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
SoundCard is a solid choice for cross-platform audio I/O in Python. It has low install friction (pure Python, two lightweight dependencies), active maintenance, permissive licensing, no known vulnerabilities, and a clear, documented API. Install it if you need speaker/microphone access without C extension overhead. Be aware that it is a hobby project—response to issues is not guaranteed to be timely—and that latency and device behavior can vary across platforms and hardware.
Install
soundcard on PyPI
Before you install
Low friction: pure Python wheel with only numpy and cffi as runtime dependencies. Active maintenance—last commit 2026-06-17, 124 days since latest release. Repository has 763 stars and is not archived, suggesting stable ongoing support.
Requires Python 3.5 or later. On Linux, PulseAudio or compatible audio system must be available; on macOS, CoreAudio; on Windows, WASAPI. Audio data must be normalized between -1 and 1 to avoid clipping.
License in practice
BSD 3-clause is permissive; you may use, modify, and distribute this package freely in commercial and private projects, provided you include the license notice and disclaimer.
Quickstart
pip install soundcard
import soundcard as sc
import numpy
# Record one second of audio
default_mic = sc.default_microphone()
data = default_mic.record(samplerate=48000, numframes=48000)
# Play back the recorded audio
default_speaker = sc.default_speaker()
default_speaker.play(data / numpy.max(numpy.abs(data)), samplerate=48000)
Verify before relying
- Whether latency tuning via blocksize and numframes parameters meets real-time or low-latency application requirements in practice.
- Support status for less common sound cards or multi-channel professional audio interfaces beyond the documented examples.
- Whether the experimental exclusive_mode flag on Windows/WASAPI is production-ready or still carries stability risks.
Package facts
| License | BSD 3-clause permissive |
| Python support | Supports the current Python release >=3.5 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 2 packagesnumpycffi |
| Maintenance | Actively maintained 124 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 126,196 / month, #11,786 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersIntended Audience :: Science/ResearchLicense :: OSI Approved :: BSD LicenseNatural Language :: EnglishOperating System :: OS IndependentProgramming Language :: Python :: 3Topic :: Multimedia :: Sound/Audio :: Capture/RecordingTopic :: Multimedia :: Sound/Audio :: Players |
Evidence: soundcard-0.4.6-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “cross-platform sound card access”
- SoundCardSoundCard plays and records audio across Linux, macOS, and Windows…
- playsoundPlays audio files (MP3, WAV) and URLs from Python with a single…
- PyAudioPyAudio provides Python bindings for PortAudio v19, enabling you to…
Give your agent the search over MCP, or paste the wish link into any chat.
More Sound/Audio packages
Reads and writes audio files in formats like WAV, FLAC, OGG, and MAT through libsndfile, exposing audio data as NumPy arrays.
Pydub provides a high-level Python interface for loading, manipulating, and exporting audio files with simple operations like slicing, concatenation, and format conversion.
However, the abandoned status since 2021-03-10 means no future fixes or compatibility updates—use it only if you can tolerate potential issues with newer Python…
Mutagen reads and writes audio metadata (tags) across many audio formats including MP3, FLAC, OGG, MP4, WavPack, and others, supporting ID3v2 and APEv2 tag editing.
Install it if you need to read or edit audio tags programmatically.
Provides PyTorch-based audio processing, transforms, and dataloaders for machine learning tasks, with GPU acceleration and autograd support for trainable audio features.
MoviePy is a Python library for video editing that reads, processes, and writes video and audio files by converting them to numpy arrays for frame-level manipulation and effect application.
Reads metadata (artist, title, duration, bitrate, and more) from audio files in formats including MP3, MP4, FLAC, OGG, WAV, and others, without writing or modifying tags.
Install it if you need to extract metadata from audio files without the overhead of a heavier library.
See also miniaudio · PyAudio · playsound · fmod-toolkit · pulsectl · pyobjc-framework-CoreAudio · pyfmodex · sonos-websocket