# Article & Web Page Text Extractor (Markdown) (`dojito/article-text-extractor`) Actor

Turn article, blog and docs URLs into clean Markdown or plain text — menus, ads and footers removed — with title, author, published date, site name and language. For LLM, RAG and research. No browser, obeys robots.txt. $1 per 1,000 pages; failed pages free.

- **URL**: https://apify.com/dojito/article-text-extractor.md
- **Developed by:** [Dongjin Kim](https://apify.com/dojito) (community)
- **Categories:** AI, News, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.90 / 1,000 page extracteds

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/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

**Article & Web Page Text Extractor** turns **article, blog post, news and documentation URLs** into the page's **main text** — as **Markdown** (headings, lists, tables kept) or **plain text** — with menus, cookie banners, ads, sidebars and footers removed. Every row also has the **title**, **author byline**, **published date** (`YYYY-MM-DD`), **site name**, **language**, description, categories / tags and **word count**.

It reads each URL **with one plain HTTP request (no browser)** — retried once after a pause if the server answers 429 / 5xx or the connection fails — obeys **robots.txt**, and never logs in or gets around paywalls. Main-text detection is done by [trafilatura](https://github.com/adbar/trafilatura), the open-source (Apache-2.0) extraction library used in many web-text research corpora. **You pay only for pages where text was actually extracted** — failed, blocked, too-short and paywalled pages are free.

### How to use

1. Paste page URLs into **Page URLs**, one per line (`https://…`).
2. Pick an **Output format**: `markdown` (default), `text` or `both`.
3. Click **Start**. Each URL gives one row in the dataset; export it as JSON, CSV, Excel or read it through the API. The **Metadata only** view leaves the long text out.

Typical uses: feeding articles into an **LLM / RAG pipeline** or a vector database, **summarising** a reading list, tracking what competitors publish, building a private research or **NLP corpus**, checking **word counts and publish dates** of content in bulk, or turning docs pages into Markdown for an AI assistant.

### What you get

One row per URL (a real result, with the author's name replaced):

```json
{
  "input": "https://github.blog/news-insights/company-news/github-availability-report-october-2026/",
  "url": "https://github.blog/news-insights/company-news/github-availability-report-october-2026/",
  "finalUrl": "https://github.blog/news-insights/company-news/github-availability-report-october-2026/",
  "statusCode": 200,
  "status": "ok",
  "extractionOk": true,
  "title": "GitHub availability report: October 2026",
  "author": "Jane Doe",
  "publishedDate": "2026-11-13",
  "siteName": "The GitHub Blog",
  "language": "en-US",
  "description": "In October, we experienced …",
  "categories": [],
  "tags": [],
  "text": null,
  "markdown": "In October, we experienced … incidents that resulted in degraded performance …\n\n### October 2 …",
  "wordCount": 3234,
  "characterCount": 20198,
  "truncated": false,
  "htmlTruncated": false,
  "error": null,
  "extractedAt": "2026-11-16T03:40:12+00:00"
}
```

| Field | Meaning |
|---|---|
| `input` | The URL exactly as you entered it |
| `url` / `finalUrl` | The URL as requested (normalised: `https://` added when missing, international characters encoded) and the URL after redirects |
| `statusCode` | HTTP status of the page (`null` when no response, e.g. DNS error or robots.txt) |
| `status` | `ok`, or why the row is free (see **Free rows**) |
| `extractionOk` | `true` = text extracted and charged; `false` = free |
| `title`, `author`, `publishedDate`, `siteName`, `description`, `categories`, `tags` | Read from the page's meta tags, JSON-LD, URL and visible text by trafilatura / htmldate. Any of them can be `null` when the page does not say |
| `language` | The language the page declares (`<html lang>`, else the `Content-Language` header) |
| `markdown` / `text` | Main text in the format(s) you chose; the other one is `null` |
| `wordCount`, `characterCount` | Size of the full main text (before **Max characters per page**) |
| `truncated` | The text was cut at **Max characters per page** |
| `htmlTruncated` | The page's HTML was larger than 5 MB and only the first 5 MB was read |
| `error` | Why a row is free, in words |
| `extractedAt` | When the row was made (UTC, ISO 8601) |

A **RUN_REPORT** record in the key-value store has the counts: rows, charged events, row statuses, duplicates skipped, characters extracted, requests sent.

### Input

| Field | Default | |
|---|---|---|
| `urls` | — | Page URLs. Each is read as given; links on the page are never followed. A URL without `https://` is tried as https, then http if https can't connect. Duplicates are removed (two URLs that redirect to the same page give one row). |
| `outputFormat` | `markdown` | `markdown`, `text` or `both` |
| `includeLinks` | `false` | Keep links as Markdown links `[text](https://…)` with absolute URLs |
| `includeTables` | `true` | Keep tables from the main content |
| `includeComments` | `false` | Add reader comments that are in the page's HTML |
| `maxCharacters` | `0` | Cut each page's text after this many characters (0 = no limit) |
| `minCharacters` | `200` | Less main text than this → `too_short`, free |
| `maxItems` | `1000` | Most rows per run (free rows included) |
| `maxConcurrency` | `5` | Pages of different websites read at the same time, at most 10 (the URLs of one website: one at a time) |
| `timeoutSecs` | `15` | Timeout per request step |

```json
{
  "urls": ["https://blog.python.org/", "https://docs.python.org/3/library/json.html"],
  "outputFormat": "markdown",
  "includeLinks": false,
  "maxItems": 1000
}
```

### Pricing

**$1.00 per 1,000 extracted pages** on the Apify Free plan, **$0.95 per 1,000** on Bronze and **$0.90 per 1,000** on Silver and higher plans — pay per event: one `page-extracted` charge per row with `extractionOk: true`, plus Apify's standard actor-start event of $0.00005 per run (one event at the default 512 MB; more if you raise memory above 1 GB) — no start fee of our own, and platform usage is included in the price. **Free:** pages that could not be read (robots.txt says no, HTTP 403 / 404 / 5xx, DNS or network errors, blocked sites, bot-protection pages, invalid URLs), pages that are not HTML (PDF, images), pages with less main text than **Min characters** (usually pages that need JavaScript), and pages that mark the article as paywalled. Duplicates give no row. **Charged:** every row with `extractionOk: true` — that includes home pages, section fronts and product pages when they have enough text, even if the result is only part of the page (see Limits). Example: 10,000 extracted pages cost $10.00 on Free, $9.00 on Silver. Set **Max pages** or a **maximum cost per run** and the actor stops cleanly when it is reached (`stoppedAtMaxItems` / `stoppedAtMaxCharge` in the run report); rows are saved as each page finishes.

### How it works

1. Each URL is checked against the actor's rules (public http(s) address on port 80/443, not a login / account / cart page, not on the never-fetch list below). Every connection goes only to a checked public IP address (no internal or cloud-metadata addresses, also after redirects).
2. The host's **robots.txt** is read once (user agent `DojitoArticleBot/1.0`); a disallowed URL is not requested. A `Crawl-delay` of up to 10 seconds is respected; a site that asks for more is not read (free `robots_txt` rows).
3. **One GET** of the URL (one retry after a 429 / 5xx answer or a failed connection), following up to 5 redirects that pass the same checks. At most **one request per second per website**, and the URLs of one website are read one at a time, so a list of 1,000 pages from one site is read politely, one after another.
4. The first 5 MB of HTML is decoded (charset from the header or `<meta>`), checked for a bot-protection page, then handed to **trafilatura** (in memory — it does not fetch anything itself), which finds the main content and the metadata. The result is written out as Markdown and / or plain text.

### Free rows

| `status` | What happened |
|---|---|
| `too_short` | Less main text than **Min characters** — often a page that builds its text with JavaScript, an index page or a login wall. The short text is still in the row. |
| `no_text` | No main text found at all |
| `paywalled` | The page's structured data says the article is not free (`isAccessibleForFree: false`). Whatever the page shows without a login is in the row; nothing is done to get past the paywall. |
| `not_html` | PDF, image or other file — use an OCR / PDF text actor |
| `bot_challenge` | The site answered with a "checking your browser" page |
| `robots_txt` | robots.txt disallows the page for this actor (or the site's robots.txt could not be read safely) |
| `http_403`, `http_404`, `http_429`, `http_5xx` … | The server's answer. Many news sites answer 403 to any automated client. |
| `dns_error`, `network_error` | The host does not exist or did not answer in time |
| `redirect_blocked` | A redirect went to a login page, a private address, a blocked site or a page robots.txt disallows |
| `terms_of_use`, `blocked_site`, `private_page`, `invalid_url` | Not requested — see below |
| `too_large` | The text did not fit in one dataset item (about 9 MB) even when cut — set **Max characters per page** |
| `internal_error` | An unexpected error on this page; the rest of the run goes on |

### Limits — be aware

- **No browser.** Pages that load their text with JavaScript (single-page apps, some news sites' live blogs) come back `too_short` and free. For those, render the page in a browser-based actor first (for example a screenshot / PDF or browser scraper actor) and extract from there.
- **Sites that refuse bots refuse this actor too.** This actor sends an honest user agent and no cookies, rotating proxies or browser fingerprints, so sites behind bot protection (Cloudflare challenge, Akamai, DataDome) or that answer 403 to automated clients give free error rows. Results vary by site, IP address and day. In our tests (November 2026) BBC, Wikipedia, GitHub Blog, MDN, Python docs, Adafruit and Yonhap worked; The Guardian, AP News and Raspberry Pi answered 403, and one Le Monde article got a challenge page.
- **Extraction is heuristic.** On article pages trafilatura is accurate, but on home pages, listings or product pages it may pick up only part of the page or some navigation text. `author` is a byline guess and can be empty or wrong on non-article pages; `publishedDate` may be the page's last-updated or first-published date when that is all it shows.
- **One page per URL.** It does not crawl a site, follow "next page" links, or merge multi-page articles.
- Pages over 5 MB of HTML are read up to 5 MB (`htmlTruncated: true`).

### Responsible use

- Only the URLs you provide are fetched; links are never followed, and robots.txt is obeyed for every page and every redirect.
- Never fetched, whatever the input: login, account, cart and checkout pages; large retailers and marketplaces whose terms prohibit robots (Amazon, eBay, Walmart, Etsy …); video, social and stock-photo platforms and their media hosts (YouTube, TikTok, Instagram, Facebook, Threads, X, LinkedIn, Pinterest, Reddit …); Google. These give free `terms_of_use` / `blocked_site` rows.
- No logins, cookies, paywall workarounds, CAPTCHA solving or proxy rotation.
- **robots.txt is the only opt-out signal read.** Text-and-data-mining reservations in other forms (TDM-Rep `tdm-reservation` meta tags, `ai.txt`, `X-Robots-Tag` / `noai` directives) are not interpreted — check them yourself if they matter for your use.
- **Names can be personal data.** `author` is the byline the page publishes, and reader comments (if you turn them on) carry commenters' names. Under GDPR / UK GDPR, PIPEDA, Korea's PIPA, CCPA and similar laws, how you store and use them is your responsibility; do not use the output to profile individuals.
- **Copyright stays with the original site.** The extracted text is meant for your own analysis, summarisation, search and RAG input. Republishing it, or using it in ways the site's terms do not allow, is your responsibility. This is general information, not legal advice.

### Compared with other actors

- **lukaskrivka/article-extractor-smart** is the long-standing free option: the actor costs nothing and you pay Apify platform usage. It can also **discover articles** by crawling a site or its sitemaps, and can open pages in a browser (more expensive). Use it if you need crawling or a browser.
- **This actor** does one step — URLs you already have → clean text — for a **fixed price per extracted page** (platform usage included, so a run never costs more than pages × price; set Max pages or a maximum cost per run), gives **Markdown** (headings, lists, tables) as well as plain text, and does **not charge** for pages that failed or returned too little text.

### FAQ

**Can it read pages behind a login or paywall?** No. It reads what the page shows to any visitor without an account; paywalled articles are marked `paywalled` and are free.

**Why did a site I can open in my browser give `http_403`?** Many sites block automated clients. This actor does not disguise itself as a browser; such pages are free.

**Is the text exactly what I see on the page?** It is the main content as trafilatura detects it: paragraphs, headings, lists, quotes, code and (optionally) tables and links. Images, videos, embedded tweets and text inside them are not included.

**Can I use it from Make, Zapier, n8n or an AI agent?** Yes — run it through the Apify API or integrations, or call it as a tool through the Apify MCP server. Runs with limited permissions.

**Which languages work?** Any language the page is written in; `wordCount` counts space-separated words, so for Chinese, Japanese or Thai use `characterCount`.

User agent: `DojitoArticleBot/1.0 (+https://apify.com; contact djkim@dojito.com)`. Questions or a site that should not be fetched: open an issue on the actor's **Issues** tab.

# Actor input Schema

## `urls` (type: `array`):

Full URLs of the pages to read (https://…). Each URL is read once, as given (international domain names and non-ASCII paths are encoded); links on the page are never followed. A URL without https:// is tried as https://, then http:// if https can't connect. Duplicates are removed. {"url": ...} objects are accepted too (API).

## `outputFormat` (type: `string`):

markdown: headings, lists, bold / italics and tables kept as Markdown (good for LLMs and RAG). text: plain text. both: two fields.

## `includeLinks` (type: `boolean`):

Keep links inside the text as Markdown links [text](https://…) — absolute URLs. Off: link text only.

## `includeTables` (type: `boolean`):

Keep tables that are part of the main content (Markdown tables; rows of cells in plain text).

## `includeComments` (type: `boolean`):

Add the reader comments found on the page after the main text (only comments that are in the page's HTML).

## `maxCharacters` (type: `integer`):

Cut the text / Markdown of each page after this many characters (truncated=true; characterCount still gives the full length). 0 = no limit.

## `minCharacters` (type: `integer`):

A page with less main text than this is returned with status too_short and is not charged (usually a page that needs JavaScript, a login wall or an index page).

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

Most rows to return (including free rows). URLs beyond this are not fetched.

## `maxConcurrency` (type: `integer`):

Pages of different websites read at the same time (default 5, at most 10 — extraction is CPU-bound, more does not make a run faster at 512 MB). Pages of one website are read one at a time, at most one request per second.

## `timeoutSecs` (type: `integer`):

How long to wait for the server at each step. A page that times out gives a free error row.

## Actor input object example

```json
{
  "urls": [
    "https://blog.python.org/",
    "https://docs.python.org/3/library/json.html",
    "https://en.wikipedia.org/wiki/Web_scraping"
  ],
  "outputFormat": "markdown",
  "includeLinks": false,
  "includeTables": true,
  "includeComments": false,
  "maxCharacters": 0,
  "minCharacters": 200,
  "maxItems": 1000,
  "maxConcurrency": 5,
  "timeoutSecs": 15
}
```

# Actor output Schema

## `overview` (type: `string`):

One row per URL: input, url, finalUrl, statusCode, status, extractionOk, title, author, publishedDate (YYYY-MM-DD), siteName, language, description, categories, tags, text, markdown, wordCount, characterCount, truncated, htmlTruncated, error, extractedAt. Only rows with extractionOk=true are charged.

## `runReport` (type: `string`):

JSON: rows, charged events, payPerEvent, row statuses (ok, too_short, no_text, paywalled, not_html, bot_challenge, robots_txt, http_4xx/5xx, dns_error, network_error, redirect_blocked, terms_of_use, blocked_site, private_page, invalid_url, too_large, internal_error), duplicates skipped, characters extracted, requests sent, user agent. Free.

# 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 = {
    "urls": [
        "https://blog.python.org/",
        "https://docs.python.org/3/library/json.html",
        "https://en.wikipedia.org/wiki/Web_scraping"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("dojito/article-text-extractor").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 = { "urls": [
        "https://blog.python.org/",
        "https://docs.python.org/3/library/json.html",
        "https://en.wikipedia.org/wiki/Web_scraping",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("dojito/article-text-extractor").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 '{
  "urls": [
    "https://blog.python.org/",
    "https://docs.python.org/3/library/json.html",
    "https://en.wikipedia.org/wiki/Web_scraping"
  ]
}' |
apify call dojito/article-text-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,dojito/article-text-extractor"
        }
    }
}
```

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/KDXXbpQMeaBhU5OZx/builds/UdPOsy0Cr1K0cj4vC/openapi.json
