skillfed

awslogs

awslogs is a simple command line tool to read aws cloudwatch logs.

awslogs v0.15.0 151.4K downloads/30d#10,934 on PyPI4,988
Permissive license BSD DORMANT released

What it is and what it does

awslogs is a lightweight CLI wrapper around boto3 for querying Amazon CloudWatch Logs. It lets you list log groups and streams, retrieve log events across multiple streams with time filtering, and watch logs in real-time—all from the command line. The tool supports human-friendly time syntax (e.g., '2h ago', '1d ago'), regex-based stream matching, CloudWatch filter patterns, and JSON query extraction, making it useful for ad-hoc log inspection and integration with Unix tools like grep.

The package depends on boto3, jmespath, termcolor, and python-dateutil. It requires Python 3.8 or later and AWS credentials configured through aws-cli, environment variables, or command-line arguments. The project is dormant but stable—no active development but no known vulnerabilities and a solid user base.

Use it for:

  • Grep logs from multiple CloudWatch streams in the last 2 hours to find ERROR entries across a log group.
  • List all log groups and streams in your AWS account without opening the AWS console.
  • Watch logs in real-time as they arrive in CloudWatch using the --watch flag.
  • Extract specific JSON fields from structured logs using --query to filter message content.
  • Retrieve logs matching a CloudWatch filter pattern to find specific event types (e.g., Lambda REPORT lines).
  • Integrate CloudWatch logs into shell scripts and CI/CD pipelines for log analysis and alerting.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

awslogs is a command-line tool for querying and streaming logs from Amazon CloudWatch, supporting log group and stream filtering, time-range queries, and real-time log watching.

Yes, if you need a lightweight CLI for CloudWatch log queries and don't require active development. The package is stable, has low install friction, and integrates well with Unix tools. The dormant maintenance status is acceptable for a mature tool with no known vulnerabilities, but expect no new features or rapid bug fixes. Use it for operational tasks and ad-hoc log inspection; avoid if you need ongoing feature development or support.

Install

awslogs on PyPI

pip

pip install awslogs

uv

uv add awslogs

poetry

poetry add awslogs

Installing awslogs

Before you install

Low install friction with four lightweight runtime dependencies. Maintenance is dormant (864 days since last release), though the repository remains active with 4988 stars and a recent commit in May 2024. Suitable for stable, established workflows but expect no active development.

License in practice

BSD permissive license allows use in commercial and proprietary projects with minimal restrictions.

Quickstart

pip install awslogs

awslogs groups
awslogs get /var/log/syslog ALL --start='2h ago' | grep ERROR

Requires AWS credentials configured via aws-cli, environment variables, or command-line flags; requires CloudWatch Logs read permissions.

Verify before relying

  • Whether the package works with boto3 versions released after May 2024.
  • Current compatibility with modern AWS CloudWatch API changes or new log features.

Package facts

License BSD (permissive)
Python support supports the current Python release (>=3.8)
Install friction low — pure-Python wheel
Runtime dependencies 4 — boto3, jmespath, termcolor, python-dateutil
Maintenance dormant — 864 days since the last release
Last repo commit
First released
Downloads 151,403/month — #10,934 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: awslogs-0.15.0-py2.py3-none-any.whl

Keywords: aws, logs, cloudwatch

Development Status :: 4 - BetaEnvironment :: Web EnvironmentIntended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Topic :: Utilities

Tags

cloudwatch logs cliaws logs command linequery cloudwatch streamsstream aws logscloudwatch log aggregationaws log filtering toolreal-time cloudwatch logs
aws-cloudwatchcli-toollog-aggregation

More Utilities packages