SkillAgentSearch skills...

Edgartools

Python library to access and analyze SEC Edgar filings, XBRL financial statements, 10-K, 10-Q, and 8-K reports

Install / Use

/learn @dgunning/Edgartools

README

<p align="center"> <a href="https://github.com/dgunning/edgartools"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/edgartools-logo.png" alt="EdgarTools Python SEC EDGAR library logo" height="80"> </a> </p> <h1 align="center">EdgarTools - Python Library for SEC EDGAR Filings</h1> <h3 align="center">The simplest, most complete Python library for SEC EDGAR data</h3> <p align="center"> <a href="https://pypi.org/project/edgartools"><img src="https://img.shields.io/pypi/v/edgartools.svg" alt="PyPI - Version"></a> <a href="https://github.com/dgunning/edgartools/actions"><img src="https://img.shields.io/github/actions/workflow/status/dgunning/edgartools/python-hatch-workflow.yml" alt="GitHub Workflow Status"></a> <a href="https://www.codefactor.io/repository/github/dgunning/edgartools"><img src="https://www.codefactor.io/repository/github/dgunning/edgartools/badge" alt="CodeFactor"></a> <a href="https://github.com/pypa/hatch"><img src="https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg" alt="Hatch project"></a> <a href="https://github.com/dgunning/edgartools/blob/main/LICENSE"><img src="https://img.shields.io/github/license/dgunning/edgartools" alt="GitHub"></a> <a href="https://pypi.org/project/edgartools"><img src="https://img.shields.io/pypi/dm/edgartools" alt="PyPI - Downloads"></a> </p> <p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/badges/badge-ai-native.svg" alt="AI Native"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/badges/badge-10x-faster.svg" alt="10x Faster"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/badges/badge-zero-cost.svg" alt="Zero Cost"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/badges/badge-production-ready.svg" alt="Production Ready"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/badges/badge-open-source.svg" alt="Open Source"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/badges/badge-financial-data.svg" alt="Financial Data"> </p> <p align="center"> <b>Get financial statements, insider trades, fund holdings, and 20+ other filing types as structured Python objects — in a few lines of code. Free and open source.</b> </p>

EdgarTools is a Python library for accessing SEC EDGAR filings as structured data. Parse financial statements, insider trades, fund holdings, proxy statements, and dozens of other filing types with a consistent Python API.

EdgarTools SEC filing data extraction demo

<p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/dividers/divider-hexagons.svg" alt=""> </p>

Why EdgarTools?

EdgarTools turns SEC filings into Python objects. Every supported form type gives you structured data — not raw HTML, not XML, not JSON dumps. Actual Python objects with properties, methods, and DataFrames.

<table align="center"> <tr> <td align="center" width="33%"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/icons/icon-speed.svg" width="80" alt="Fast"><br> <b>Fast</b><br> Optimized with lxml & PyArrow<br> Smart caching, rate-limit aware </td> <td align="center" width="33%"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/icons/icon-ai.svg" width="80" alt="AI Ready"><br> <b>AI Ready</b><br> Built-in MCP server for Claude<br> LLM-optimized text extraction </td> <td align="center" width="33%"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/icons/icon-quality.svg" width="80" alt="Well Tested"><br> <b>Well Tested</b><br> 1000+ verification tests<br> Type hints throughout </td> </tr> <tr> <td align="center" width="33%"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/icons/icon-xbrl.svg" width="80" alt="XBRL Support"><br> <b>XBRL Native</b><br> Full XBRL standardization<br> Cross-company comparisons </td> <td align="center" width="33%"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/icons/icon-data.svg" width="80" alt="20+ Filing Types"><br> <b>20+ Filing Types</b><br> Typed objects for every form<br> Pandas-ready DataFrames </td> <td align="center" width="33%"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/icons/icon-community.svg" width="80" alt="Open Source"><br> <b>Open Source</b><br> MIT license, free forever<br> No API keys, no rate limits </td> </tr> </table> <p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/dividers/divider-hexagons.svg" alt=""> </p>

How It Works

<p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/how-it-works.svg" alt="How EdgarTools Python library extracts SEC EDGAR filing data"> </p> <p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/dividers/divider-hexagons.svg" alt=""> </p> <p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/sections/section-quick-start.svg" alt="Quick Start"> </p>
pip install edgartools

from edgar import *
set_identity("your.name@example.com")

# Get a company's balance sheet
balance_sheet = Company("AAPL").get_financials().balance_sheet()

# Browse a company's filings
company = Company("MSFT")

# Parse insider transactions
filings = company.get_filings(form="4")
form4 = filings[0].obj()

Apple SEC Form 4 insider transaction data extraction with Python

<p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/dividers/divider-hexagons.svg" alt=""> </p>

Use Cases

Analyze 13F Institutional Holdings & Hedge Fund Portfolios

Track what hedge funds and institutional investors own by parsing SEC 13F filings. EdgarTools extracts complete portfolio holdings with position sizes, values, and quarter-over-quarter changes.

from edgar import get_filings
thirteenf = get_filings(form="13F-HR")[0].obj()
thirteenf.holdings  # DataFrame of all portfolio positions

Institutional Holdings guide →

Track Insider Trading with SEC Form 4

Monitor insider buying and selling activity from SEC Form 4 filings. See which executives are purchasing or selling shares, option exercises, and net position changes.

company = Company("TSLA")
form4 = company.get_filings(form="4")[0].obj()
form4.transactions  # Insider buy/sell transactions

Insider Trades guide →

Extract Financial Statements from 10-K and 10-Q Filings

Get income statements, balance sheets, and cash flow statements from SEC annual and quarterly reports. Data is parsed from XBRL with standardized labels for cross-company comparison.

financials = Company("MSFT").get_financials()
financials.balance_sheet()   # Balance sheet with all line items
financials.income_statement()  # Revenue, net income, EPS

Financial Statements guide →

Parse 8-K Current Reports for Corporate Events

Access material corporate events as they happen -- earnings releases, acquisitions, executive changes, and more. EdgarTools parses 8-K filings into structured items with full text extraction.

eightk = get_filings(form="8-K")[0].obj()
eightk.items  # List of reported event items

Current Events guide →

Query XBRL Financial Data Across Companies

Access structured XBRL financial facts for any SEC filer. Query specific line items like revenue or total assets over time, and compare across companies using standardized concepts.

facts = Company("AAPL").get_facts()
facts.to_pandas("us-gaap:Revenues")  # Revenue history as DataFrame

XBRL Deep Dive →

<p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/dividers/divider-hexagons.svg" alt=""> </p> <p align="center"> <img src="https://raw.githubusercontent.com/dgunning/edgartools/main/docs/images/sections/section-features.svg" alt="Key Features"> </p>

Comprehensive SEC Data Access

<table> <tr> <td width="50%" valign="top">

Financial Statements (XBRL)

  • Balance Sheets, Income Statements, Cash Flows
  • Individual line items via XBRL tags
  • Multi-period comparisons with comparative periods
  • Standardized cross-company data
  • Automatic unit conversion
  • Metadata columns (dimensions, members, units)
  • Complete dimensional data support

Fund & Investment Data

  • 13F institutional holdings & portfolio analysis
  • N-PORT fund portfolio data
  • N-MFP money market fund holdings
  • N-CSR/N-CEN fund reports
  • Position tracking over time

Company Dataset & Reference Data

  • Industry and state filtering
  • Company subsets with metadata
  • Standardized industry classifications
  • SEC ticker/CIK lookups
  • Exchange information

Insider Transactions

  • Form 3, 4, 5 structured data
  • Transaction history by insider
  • Ownership changes
  • Grant and exercise details
  • Automatic parsing
</td> <td width="50%" valign="top">

Filing Intelligence

  • Any form type (10-K, 10-Q, 8-K, S-1, etc.)
  • Complete history since 1994
  • Typed data objects for 20+ form types
  • HTML to clean text extraction
  • Section

Related Skills

View on GitHub
GitHub Stars1.9k
CategoryDevelopment
Updated2h ago
Forks328

Languages

Python

Security Score

100/100

Audited on Mar 27, 2026

No findings