localstack-client
A lightweight Python client for LocalStack.
What it is and what it does
localstack-client is a thin Python wrapper around boto3 that automatically configures AWS API endpoints to point to a local LocalStack instance instead of real AWS. It lets you write code using the standard boto3 API—creating S3 buckets, queuing messages to SQS, or any other AWS service operation—but have those calls execute against your local development environment.
The package supports multiple usage patterns: you can import it as a drop-in replacement for boto3, instantiate a session directly, or use a patch function to transparently redirect existing boto3 calls. Configuration is handled via environment variables like AWS_ENDPOINT_URL, LOCALSTACK_HOST, and USE_SSL. It has no external runtime dependencies and supports Python 3.8, 3.9, 3.10, 3.11, 3.12, and 3.13.
Use it for:
- Write integration tests for AWS-dependent code without provisioning real cloud resources or incurring costs.
- Develop and debug multi-service cloud applications locally using S3, SQS, and other AWS services.
- Mock boto3 calls in pytest fixtures to test code that uses boto3 without modifying the original source.
- Prototype and iterate on cloud infrastructure code before deploying to production AWS.
- Run CI/CD pipelines that exercise AWS service interactions in an isolated, reproducible local environment.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
A Python client that wraps boto3 to redirect AWS API calls to a local LocalStack instance for development and testing without hitting real AWS.
Yes, if you are developing or testing AWS-dependent Python code and have LocalStack running locally. The high install friction is a minor drawback, but active maintenance, permissive license, zero runtime dependencies, and no known vulnerabilities make it solid for local cloud development. Not worth installing if you do not use boto3 or do not have LocalStack set up.
Install
localstack-client on PyPI
pip
pip install localstack-clientuv
uv add localstack-clientpoetry
poetry add localstack-clientInstalling localstack-client
Before you install
High install friction due to a source distribution requirement. The package is actively maintained with a recent release, but installation will require a build step rather than a wheel.
License in practice
Licensed under Apache License 2.0 (permissive), allowing commercial and private use with minimal restrictions.
Quickstart
pip install localstack-client
import localstack_client.session as boto3
client = boto3.client('s3')
response = client.list_buckets()
LocalStack must be installed and running locally; the localstack command needs to be available.
Verify before relying
- Specific LocalStack server versions or release cycles that this client version is compatible with.
- Whether all AWS services supported by boto3 are fully functional through this wrapper.
Package facts
| License | Apache License 2.0 (permissive) |
| Python support | not specified |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | actively maintained — 24 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 964,129/month — #4,627 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: localstack_client-2.12.tar.gz
Tags
More Testing packages
Pluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
virtualenvvirtualenv creates isolated Python environments…
permissive · top 100 on PyPI
coverageCoverage.py measures which lines of Python code…
permissive · top 1,000 on PyPI
pytest-asynciopytest-asyncio is a pytest plugin that enables…
permissive · top 1,000 on PyPI
pytest-json-ctrfA pytest plugin that generates test reports in…
permissive · top 1,000 on PyPI
awscli-localProvides the `awslocal` command, a thin wrapper…
permissive · top 5,000 on PyPI
moto-extMocks AWS services for testing by intercepting…
permissive · top 15,000 on PyPI
terraform-localA wrapper script that runs Terraform against…
permissive · top 15,000 on PyPI
localstackLocalStack is a command-line tool that emulates…
permissive · top 15,000 on PyPI
localstack-extProvides extensions and additional…
unclear · top 15,000 on PyPI
pulumi-localA command-line wrapper that adapts Pulumi…
permissive · top 15,000 on PyPI
aws-error-utilsWraps botocore ClientError exceptions to…
permissive · top 15,000 on PyPI
motoMoto mocks AWS services for testing, allowing…
permissive · top 1,000 on PyPI
botoBoto is a Python interface to Amazon Web…
permissive · top 5,000 on PyPI
aiomotoProvides async-compatible AWS service mocks for…
permissive · top 15,000 on PyPI