# CourtListener Opinions Scraper (`parseforge/courtlistener-scraper`) Actor

Scrape US court opinions from CourtListener by search query or as a live feed of the latest rulings. Returns each opinion with its case metadata, citation, court, and judge in a flat row.

- **URL**: https://apify.com/parseforge/courtlistener-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.62 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

[![ParseForge](https://raw.githubusercontent.com/ParseForge/apify-assets/main/banner.jpg)](https://apify.com/parseforge?fpr=vmoqkp)

### CourtListener Opinions Scraper

**Scrape US court opinions from CourtListener by keyword or catch the latest rulings, up to a million per run.** Every opinion returns with its full case metadata, citation, judge, and court. No API key required.

CourtListener's official API requires registration, throttles requests, and limits the shape of data you can pull. This reads the public opinion search directly, letting you pull case law by search term or scrape the newest decisions as they are filed. Each match drops into your dataset as one clean row, ready for analysis.

| Who uses it | What they scrape CourtListener for |
|---|---|
| Legal data analysts | Chart how often a specific judge cites precedent on Fourth Amendment cases. |
| Law firms | Monitor new appellate rulings that cite their past wins. |
| Academic researchers | Build a corpus of federal district court opinions on patent eligibility. |
| Investigative journalists | Track rulings from a particular circuit on FOIA disputes. |

### What it does

This Actor collects US court opinions from CourtListener's public search by keyword or as a live feed of recent filings, and returns each opinion as a flat row.

- 🔍 **Keyword search:** Enter any legal phrase, case citation, or party name and pull every matching opinion.
- 🆕 **Latest opinions feed:** Leave the search empty and the Actor returns the newest decisions filed on CourtListener.
- ⚙️ **Max items control:** Stop the run after a chosen number of opinions, from a 10-item preview up to a million.

Results export to CSV, JSON, Excel, or XML, or straight from the API.

### What you can do with CourtListener data

**📈 Track judicial trends on a topic.**

A legal tech startup enters 'generative AI' daily and feeds each opinion's judge and circuit into a dashboard showing which courts rule on AI copyright questions most often.

**⚖️ Monitor new rulings that cite your firm's cases.**

A litigation firm leaves the search blank and runs the Actor weekly, then filters the dataset for opinions that mention their past appellate wins by citation.

**📚 Build a research dataset for empirical legal studies.**

A law professor queries 'qualified immunity' across all circuits, collects five thousand opinions, and codes each one for outcome and reasoning in a statistical model.

**🗞️ Investigate a judge's full published record.**

A reporter searches for a newly appointed circuit judge's name, pulls every opinion they authored, and maps how often they side with the government in immigration appeals.

### Why choose this scraper

| | What you get |
|---|---|
| **No CourtListener API key** | Bypasses registration and rate limits by reading the public search directly. |
| **Full case metadata** | Each row carries the court, judge, citation, filing date, and the opinion's status. |
| **One fixed output schema** | Every result follows the same flat structure, no matter which court or query produced it. |

### How it compares

This Actor targets CourtListener's opinion search with a clean keyword-or-newest interface, while competing scrapers add docket and party filters or MCP tooling for AI assistants.

| Feature | ParseForge | Court Records Scraper | CourtListener Opinion Scraper - US Court Case Law API |
|---|---|---|---|
| Plain keyword search for opinions | Yes, with newest-opinions fallback when left blank | Yes | Yes |
| No API key or registration required | Yes | Yes | Not listed |
| Filter by specific court or judge | Yes, via search query | Yes | Yes |
| Filter by date range natively | Not listed | Yes | Yes |
| Dockets and case party extraction | Not listed | Yes | Not listed |

### Configure the run

Drive the Actor with a search query for targeted opinions or leave it blank to fetch the newest filings, and set a ceiling on the number of results returned. The Input tab lists every parameter.

A first run with the defaults:

```json
{
 "maxItems": 10
}
```

A larger pull:

```json
{
 "maxItems": 200
}
```

### Pricing

Pay-per-result: **$0.004 per result** collected. You pay only for the results written to your dataset.

| Results collected | Approximate cost |
|---|---|
| 100 results | $0.40 |
| 1,000 results | $4.00 |
| 10,000 results | $40.00 |

New Apify accounts start with $5 in free credit.

### Free users

Free-plan runs return up to 10 results as a preview. [Upgrade your Apify plan](https://console.apify.com/sign-up?fpr=vmoqkp) to collect up to 1,000,000 results per run.

### Run it

1. [Create a free Apify account with $5 in credit](https://console.apify.com/sign-up?fpr=vmoqkp).
2. Open the [CourtListener Opinions Scraper](https://apify.com/parseforge/courtlistener-scraper?fpr=vmoqkp).
3. Set your inputs and any filters, then click **Start**.
4. Export the results as CSV, Excel, JSON, or XML from the **Dataset** tab.

Run it programmatically through the [Apify API](https://docs.apify.com/api/v2) (`run-sync-get-dataset-items`) or the [ApifyClient](https://docs.apify.com/api/client/js) for JavaScript and Python.

### Use with AI agents (MCP)

Give an AI agent live access to CourtListener through the Model Context Protocol. Add the Actor to Claude, Cursor, or any MCP client:

```bash
claude mcp add --transport http apify "https://mcp.apify.com?tools=parseforge/courtlistener-scraper"
```

Then prompt it in plain language to run the scraper and read back the results.

### Troubleshooting

**Why am I getting no results for my search query?**

CourtListener's search may not return opinions that match your exact phrase. Try shorter keywords, remove quotes, or check if you misspelled a party name or citation. Leaving the query blank will always pull the newest opinions if no search term works.

**Why is my run stuck or taking a very long time?**

Large max item counts scan many pages. CourtListener's servers may throttle aggressive requests. Lower your max items or add a short delay between requests if your tooling allows it. The Actor respects public load and may pause naturally.

**The data I scraped is missing a field I expected, like judge or citation.**

Not every CourtListener opinion entry includes every metadata field. State court opinions, very old cases, or pro se filings sometimes lack a judge name or official citation. The Actor returns whatever data the public page contains.

**I get an error about max items when I try to run the Actor.**

Free tier runs are limited to a max of 10 items. If you set a higher number, the run may fail. Upgrade to a paid Apify plan to lift the cap and scrape up to 1,000,000 opinions per run.

**Can I scrape by date range instead of keyword?**

CourtListener's public search does not expose native date range filters in the URL this Actor reads. To approximate this, use search terms like a year or month name, or scrape the newest opinions feed and filter the resulting dataset locally.

### FAQ

| Question | Answer |
|---|---|
| Do I need a CourtListener API key to use this scraper? | No. The Actor reads the public CourtListener opinion search pages, so no registration, API key, or OAuth flow is required. |
| How many opinions can I scrape in a single run? | Free runs are capped at 10 items for a preview. Paid users can set the max items as high as 1,000,000 per run. |
| What data does the scraper return for each opinion? | Every item includes the case name, court, judge, filing date, citation, docket number, and other metadata fields CourtListener provides in its public view. |
| Can I scrape opinions from a specific court or judge? | Yes. Use the search query field and include the court name or judge's full name in quotes. The scraper passes your terms directly to CourtListener's own search engine. |
| How do I get the newest opinions without a search term? | Leave the search query field empty. The Actor will scrape the most recent opinions filed across all jurisdictions on CourtListener. |
| Does this scraper work with RECAP docket documents? | This Actor targets CourtListener's opinion search. It does not pull individual RECAP docket PDFs or filings. For docket data, a dedicated RECAP actor would be needed. |
| Is this an official CourtListener product? | No. It is an independent scraper built on ParseForge that reads publicly available opinion pages. It is not made or endorsed by the Free Law Project. |
| What export formats are available for the scraped data? | You can export your dataset in JSON, CSV, Excel, XML, or RSS from the Apify platform once the run finishes. |
| Can I schedule this scraper to run automatically? | Yes. Use Apify's scheduler to run the Actor daily, weekly, or on any cron schedule, so you always get fresh opinions without manual effort. |
| How do I cite scraped CourtListener opinions in my research? | Each opinion comes with its official citation and URL when available. Check CourtListener's own citation guidelines to credit the source correctly in your work. |

### Related actors

Browse the full [ParseForge collection](https://apify.com/parseforge?fpr=vmoqkp) for more scrapers.

🆘 **Need help?** Email parseforge@protonmail.com with your run ID, your input, and what you expected.

⚠️ **Disclaimer.** This Actor is unofficial and is not affiliated with, endorsed by, or sponsored by Free Law Project. It collects only publicly available data. You are responsible for using the collected data in compliance with the source's terms of service and applicable data-protection laws, including GDPR, CCPA, and PIPL. Do not use it to collect personal data unlawfully.

# Actor input Schema

## `searchQuery` (type: `string`):

Enter search terms to find opinions (e.g., 'civil rights', 'patent'). Leave empty to get latest opinions.

## `maxItems` (type: `integer`):

Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000

## Actor input object example

```json
{
  "maxItems": 10
}
```

# Actor output Schema

## `results` (type: `string`):

Complete dataset of all scraped records.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/courtlistener-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "maxItems": 10 }

# Run the Actor and wait for it to finish
run = client.actor("parseforge/courtlistener-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "maxItems": 10
}' |
apify call parseforge/courtlistener-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parseforge/courtlistener-scraper"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/nqITzEEdLIl441S08/builds/oFEdrLF5EdHIA1gnt/openapi.json
