Blog / Insider trading
Insider trading

How to Track Insider Buying and Selling With Public Data

A practical guide to tracking insider buying and selling using public Form 4 data, including real time alerts, filters and historical bulk downloads.

By the SecFeed teamOctober 12, 20266 min read
Key takeaways

An insider trading tracker is any tool that watches Form 3, 4 and 5 filings and surfaces the transactions that matter: who bought, who sold, how much and when. Building one well is less about finding the data, which is free and public, and more about filtering out noise and deciding how fresh the feed needs to be. This guide walks through the design choices and the API calls behind each one.

What the underlying data actually is

Everything an insider trading tracker shows comes from three EDGAR forms, all filed under Section 16(a) of the Securities Exchange Act of 1934:

FormPurpose
Form 3Initial statement of beneficial ownership, filed when someone becomes an insider
Form 4Changes in ownership, filed within two business days of most transactions
Form 5Annual statement covering a small number of transactions eligible for deferred reporting

Each filing lists one or more transactions, each tagged with a one letter code such as P for an open market purchase or S for an open market sale. A tracker's first job is reading that code correctly, because a large dollar figure next to code F (shares withheld for taxes) or code M (an option exercise) is not the same signal as the same figure next to code P or S.

Deciding what counts as signal

Raw Form 4 data includes a lot of activity that is mechanical rather than discretionary: tax withholding, scheduled option exercises, 10b5-1 plan trades set up months earlier, and small routine transactions. A useful tracker applies filters before showing anything to a user:

None of these filters turn insider data into a trading signal. They only separate discretionary activity from mechanical activity. What any individual insider's trade means for the company is a judgment call, not something the filing states.

Get this data as clean JSON

SecFeed turns SEC filings into structured data with one API call: GET /v1/insider-trading?code=P&minValue=100000. 500 free calls a month.

Get a free API key →

Querying insider transactions

SecFeed parses every Form 3, 4 and 5 into rows with the transaction code, price, share counts and the 10b5-1 flag already extracted, so a tracker does not need to parse XML itself. To watch purchases over $100,000 across every company:

curl "https://secfeedapi.com/v1/insider-trading?code=P&minValue=100000&size=25" \
  -H "Authorization: Bearer YOUR_API_KEY"

To watch one company instead, filter by ticker or CIK:

from secfeed import Client

sf = Client("YOUR_API_KEY")
rows = sf.insider_trades(ticker="NVDA", code="S", minValue=250000)
for r in rows:
    print(r["owner"], r["code"], r["shares"], r["price"], r["transactionDate"])

The same endpoint accepts a table parameter to separate non-derivative transactions (common stock) from derivative transactions (options and similar instruments), and an owner parameter to follow a specific person by name across every company they file for.

Making it real time

A tracker that only checks once a day will always be a day behind. There are two ways to get closer to real time:

  1. Server sent events. The /v1/stream endpoint pushes each new filing the moment EDGAR publishes it, and accepts a formTypes filter so you can subscribe to form 4 alone.
  2. Webhooks. /v1/webhooks lets you register an HTTPS endpoint and a list of form types or CIKs, and SecFeed posts each matching filing to your endpoint as it arrives, instead of you polling.
curl -X POST "https://secfeedapi.com/v1/webhooks" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{"url": "https://example.com/hooks/insiders", "formTypes": ["4"], "ciks": ["320193"]}'

Either approach removes the need to poll the search endpoint on a schedule and parse out what changed since the last check.

Building history instead of a live feed

Live monitoring answers "what just happened." Research questions, like how often a company's directors have bought shares around earnings dates over the last two years, need history instead. Replaying years of individual filings through a search endpoint is slow. The /v1/bulk/download endpoint serves a full month of a dataset as gzipped JSON Lines, which is a better fit for that kind of analysis:

curl "https://secfeedapi.com/v1/bulk/download?dataset=insider-transactions&month=2026-09" \
  -H "Authorization: Bearer YOUR_API_KEY" -o 2026-09.jsonl.gz

Downloading a run of months and loading them into a dataframe is usually faster than paging through the search endpoint one request at a time.

A simple tracker design

A reasonable starting design combines the pieces above:

  1. Subscribe to a webhook for form type 4, optionally scoped to a watchlist of CIKs.
  2. On each incoming filing, keep only lines with code P or S above a minimum dollar value.
  3. Store the result somewhere you control, so you are not re-querying the API for history you already have.
  4. Backfill with /v1/bulk/download to seed history before the webhook was set up.
Store the raw transaction code and the 10b5-1 flag alongside every row you keep, even if your current filter discards most codes. You will want them later if you change your filtering rules.

Frequently asked questions

Yes. Form 3, 4 and 5 filings are public records that the SEC requires insiders to disclose. Reading, storing and analyzing them is unrestricted. "Insider trading" as a legal violation refers to trading on material nonpublic information, which is a separate matter investigated by the SEC and is not what a public filings tracker observes.

How fast can a tracker see a new Form 4?

As fast as EDGAR publishes it. A webhook or server sent events subscription delivers each new filing within moments of its acceptance by EDGAR, rather than waiting for the next scheduled poll.

Does a large insider purchase predict the stock's future price?

The filing does not say, and no public dataset can answer that reliably. Treat insider transactions as one input to understand ownership changes, not as a standalone signal.

What is the difference between tracking by ticker and tracking by owner?

Tracking by ticker shows every insider transaction at one company. Tracking by owner follows one person's transactions across every company where they hold an insider role, which matters for people who sit on multiple boards.

Can I track Form 3 filings too?

Yes. The same insider trading endpoint covers Forms 3 and 5 alongside Form 4, so you can see a new insider's starting position as well as every later change. See the insider trading endpoint for the full parameter list, and read more about the underlying form in SEC Form 4 Explained.

Get this data as clean JSON

SecFeed turns SEC filings into structured data with one API call: GET /v1/insider-trading?code=P&minValue=100000. 500 free calls a month.

Get a free API key →

For information only, not investment advice. Data from public SEC filings; verify important figures on SEC.gov. See our AI Disclosure.