---
title: "Scrape a single URL and optionally extract information using an LLM"
method: POST
path: "/scrape"
tags: ["Scraping"]
---

# Scrape a single URL and optionally extract information using an LLM

`POST /scrape`

## Request body

- object
  - `url` string, uri, required — The URL to scrape
  - `formats` union[] — Output formats to include in the response. You can specify one or more formats, either as strings (e.g., `'markdown'`) or as objects with additional options (e.g., `{ type: 'json', schema: {...} }`). Some formats require specific options to be set. Example: `['markdown', { type: 'json', schema: {...} }]`.
    - union
      - object
        - `type` 'markdown', required
      - object
        - `type` 'summary', required
      - object
        - `type` 'html', required
      - object
        - `type` 'rawHtml', required
      - object
        - `type` 'links', required
      - object
        - `type` 'images', required
      - object
        - `type` 'screenshot', required
        - `fullPage` boolean — Whether to capture a full-page screenshot (ignores viewport.height) or limit to the current viewport.
        - `quality` integer — The quality of the screenshot, from 1 to 100. 100 is the highest quality.
        - `viewport` object
          - `width` integer, required — The width of the viewport in pixels
          - `height` integer, required — The height of the viewport in pixels
      - object
        - `type` 'json', required
        - `schema` object — The schema to use for the JSON output. Must conform to [JSON Schema](https://json-schema.org/).
        - `prompt` string — The prompt to use for the JSON output
      - object
        - `type` 'changeTracking', required
        - `modes` string[] — The mode to use for change tracking. 'git-diff' provides a detailed diff, and 'json' compares extracted JSON data.
        - `schema` object — Schema for JSON extraction when using 'json' mode. Defines the structure of data to extract and compare. Must conform to [JSON Schema](https://json-schema.org/).
        - `prompt` string — Prompt to use for change tracking when using 'json' mode. If not provided, the default prompt will be used.
        - `tag` string, nullable — Tag to use for change tracking. Tags can separate change tracking history into separate "branches", where change tracking with a specific tagwill only compare to scrapes made in the same tag. If not provided, the default tag (null) will be used.
      - object
        - `type` 'branding', required
      - object
        - `type` 'product', required
      - object
        - `type` 'menu', required
      - object — Extract audio (MP3) from supported video URLs, e.g. YouTube. Returns a signed GCS URL.
        - `type` 'audio', required
      - object — Extract best-quality video from supported video URLs, e.g. YouTube. Returns a signed GCS URL.
        - `type` 'video', required
      - object — Ask a natural-language question about the page. Returns the answer in the response `answer` field.
        - `type` 'question', required
        - `question` string, required — The question to answer about the page. Maximum 10,000 characters.
      - object — Find relevant source text from the page. Returns the selected text in the response `highlights` field.
        - `type` 'highlights', required
        - `query` string, required — The text-selection query to run against the page. Maximum 10,000 characters.
  - `onlyMainContent` boolean — Only return the main content of the page excluding headers, navs, footers, etc. This is a deterministic HTML-level filter applied before markdown is generated; no LLM is involved.
  - `onlyCleanContent` boolean — Beta. Run an additional LLM-based pass over the generated markdown to remove residual boilerplate that `onlyMainContent` can miss (cookie banners, ad blocks, social share widgets, breadcrumbs, newsletter signups, comment sections, related-article lists). Headings, lists, tables, code blocks, image references, and inline links are preserved. Can be combined with `onlyMainContent` (the most common setup) or used on its own. Skipped with a warning when the markdown exceeds the cleaning model's output token limit (the original markdown is preserved). Not supported on zero-data-retention requests.
  - `includeTags` string[] — Tags to include in the output.
  - `excludeTags` string[] — Tags to exclude from the output.
  - `maxAge` integer — Returns a cached version of the page if it is younger than this age in milliseconds. If a cached version of the page is older than this value, the page will be scraped. If you do not need extremely fresh data, enabling this can speed up your scrapes by 500%. Defaults to 2 days.
  - `minAge` integer — When set, the request only checks the cache and never triggers a fresh scrape. The value is in milliseconds and specifies the minimum age the cached data must be. If matching cached data exists, it is returned instantly. If no cached data is found, a 404 with error code SCRAPE_NO_CACHED_DATA is returned. Set to 1 to accept any cached data regardless of age.
  - `headers` object — Headers to send with the request. Can be used to send cookies, user-agent, etc.
  - `waitFor` integer — Specify a delay in milliseconds before fetching the content, allowing the page sufficient time to load. This waiting time is in addition to Firecrawl's smart wait feature.
  - `mobile` boolean — Set to true if you want to emulate scraping from a mobile device. Useful for testing responsive pages and taking mobile screenshots.
  - `skipTlsVerification` boolean — Skip TLS certificate verification when making requests.
  - `timeout` integer — Timeout in milliseconds for the request. Minimum is 1000 (1 second). Default is 60000 (60 seconds). Maximum is 300000 (300 seconds).
  - `parsers` object[] — Controls how files are processed during scraping. When "pdf" is included (default), the PDF content is extracted and converted to markdown format, with billing based on the number of pages (1 credit per page). When an empty array is passed, the PDF file is returned in base64 encoding with a flat rate of 1 credit for the entire PDF.
    - `type` 'pdf', required
    - `mode` 'fast' | 'auto' | 'ocr' — PDF parsing mode. "fast": text-based extraction only (embedded text, fastest). "auto" (default): attempts fast extraction first, falls back to OCR if needed. "ocr": forces OCR parsing on every page.
    - `maxPages` integer — Maximum number of pages to parse from the PDF. Must be a positive integer up to 10000.
  - `actions` union[] — Actions to perform on the page before grabbing the content
    - union
      - object
        - `type` 'wait', required — Wait for a specified amount of milliseconds
        - `milliseconds` integer, required — Number of milliseconds to wait
      - object
        - `type` 'wait', required — Wait for a specific element to appear
        - `selector` string, required — CSS selector to wait for
      - object
        - `type` 'screenshot', required — Take a screenshot. The links will be in the response's `actions.screenshots` array.
        - `fullPage` boolean — Whether to capture a full-page screenshot (ignores viewport.height) or limit to the current viewport.
        - `quality` integer — The quality of the screenshot, from 1 to 100. 100 is the highest quality.
        - `viewport` object
          - `width` integer, required — The width of the viewport in pixels
          - `height` integer, required — The height of the viewport in pixels
      - object
        - `type` 'click', required — Click on an element
        - `selector` string, required — Query selector to find the element by
        - `all` boolean — Clicks all elements matched by the selector, not just the first one. Does not throw an error if no elements match the selector.
      - object
        - `type` 'write', required — Write text into an input field, text area, or contenteditable element. Note: You must first focus the element using a 'click' action before writing. The text will be typed character by character to simulate keyboard input.
        - `text` string, required — Text to type
      - object — Press a key on the page. See https://asawicki.info/nosense/doc/devices/keyboard/key_codes.html for key codes.
        - `type` 'press', required — Press a key on the page
        - `key` string, required — Key to press
      - object
        - `type` 'scroll', required — Scroll the page or a specific element
        - `direction` 'up' | 'down' — Direction to scroll
        - `selector` string — Query selector for the element to scroll
      - object
        - `type` 'scrape', required — Scrape the current page content, returns the url and the html.
      - object
        - `type` 'executeJavascript', required — Execute JavaScript code on the page
        - `script` string, required — JavaScript code to execute
      - object
        - `type` 'pdf', required — Generate a PDF of the current page. The PDF will be returned in the `actions.pdfs` array of the response.
        - `format` 'A0' | 'A1' | 'A2' | 'A3' | 'A4' | 'A5' | 'A6' | 'Letter' | 'Legal' | 'Tabloid' | 'Ledger' — The page size of the resulting PDF
        - `landscape` boolean — Whether to generate the PDF in landscape orientation
        - `scale` number — The scale multiplier of the resulting PDF
  - `location` object — Location settings for the request. When specified, this will use an appropriate proxy if available and emulate the corresponding language and timezone settings. Defaults to 'US' if not specified.
    - `country` string — ISO 3166-1 alpha-2 country code (e.g., 'US', 'AU', 'DE', 'JP')
    - `languages` string[] — Preferred languages and locales for the request in order of priority. Defaults to the language of the specified location. See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Language
  - `removeBase64Images` boolean — Removes all base 64 images from the markdown output, which may be overwhelmingly long. This does not affect html or rawHtml formats. The image's alt text remains in the output, but the URL is replaced with a placeholder.
  - `blockAds` boolean — Enables ad-blocking and cookie popup blocking.
  - `proxy` 'basic' | 'enhanced' | 'auto' — Specifies the type of proxy to use. - **basic**: Proxies for scraping sites with none to basic anti-bot solutions. Fast and usually works. - **enhanced**: Enhanced proxies for scraping sites with advanced anti-bot solutions. Slower, but more reliable on certain sites. Costs up to 5 credits per request. - **auto**: Firecrawl will automatically retry scraping with enhanced proxies if the basic proxy fails. If the retry with enhanced is successful, 5 credits will be billed for the scrape. If the first attempt with basic is successful, only the regular cost will be billed.
  - `storeInCache` boolean — If true, the page will be stored in the Firecrawl index and cache. Setting this to false is useful if your scraping activity may have data protection concerns. Using some parameters associated with sensitive scraping (e.g. actions, headers) will force this parameter to be false.
  - `lockdown` boolean — If true, serves the request from Firecrawl's cache only and never makes an outbound request to the target URL. Designed for compliance-constrained or air-gapped environments where the scrape request itself could leak sensitive information. On cache miss, returns a 404 with error code SCRAPE_LOCKDOWN_CACHE_MISS (the URL is never logged on miss). Lockdown requests are treated as zero data retention. Default maxAge is extended to 2 years so existing cached pages remain eligible. Billed at 5 credits on hit, 1 credit on cache miss.
  - `redactPII` union — Redact personally identifiable information from returned markdown. Pass `true` to use defaults, or an object to tune mode, entities, and replacement style.
    - boolean
    - RedactPIIOptions — Tuning options for PII redaction.
      - `mode` 'accurate' | 'aggressive' | 'fast' — Redaction strategy. `accurate` is model-only and optimized for precision, `aggressive` increases recall with additional heuristics, and `fast` uses heuristics without the model call.
      - `entities` RedactPIIEntity[] — Restrict redaction to these entity buckets. If omitted, all supported entities are redacted.
      - `replaceStyle` 'tag' | 'mask' | 'remove' — `tag` replaces spans with placeholders like `<EMAIL>`, `mask` replaces characters with `*`, and `remove` deletes the span text.
  - `profile` object — Enable persistent browser storage across scrape and interact sessions. Pass a profile when scraping to preserve cookies, localStorage, and session data. Sessions with the same profile name share browser state.
    - `name` string, required — A name for the profile. Scrapes with the same name share browser state (cookies, localStorage, sessions).
    - `saveChanges` boolean — When true, browser state is saved back to the profile when the interact session stops. Set to false to load existing data without writing. Only one saving session is allowed at a time.
  - `threatProtection` ThreatProtectionOverride — Per-request [Threat Protection](https://docs.firecrawl.dev/features/threat-protection) override. Fields you provide replace the corresponding fields of your organization's policy for this request only; omitted fields keep their organization-level values. Requires Threat Protection to be enabled for your team (enterprise feature) — otherwise the request is rejected with a 403. If your organization has disabled request overrides, any request that includes this object is rejected with a 403. If Threat Protection is enforced for your team, `mode` may not be set to `off`.
    - `mode` 'off' | 'normal' — URL scanning mode for this request. `normal` checks URLs against Google Web Risk (+2 credits per URL scanned).
    - `riskScoreThreshold` integer — Normalized risk score (0–100) at or above which a classifier verdict blocks the URL. Lower is stricter.
    - `blacklist` string[] — Domains to always block, as plain domains (`example.com`) or wildcard globs (`*.example.com`). No protocol, path, or port.
    - `whitelist` string[] — Domains to always allow, as plain domains or wildcard globs. Wins over every other rule.
    - `blockedTlds` string[] — Top-level domains to block outright, lowercase without the leading dot (e.g. `zip`).
    - `failurePolicy` 'open' | 'closed' — What to do when the classifier can't be reached: `closed` blocks the request, `open` allows it.
  - `zeroDataRetention` boolean — If true, this will enable zero data retention for this scrape. To enable this feature, please contact help@firecrawl.dev

## Response `200`

Successful response

- ScrapeResponse
  - `success` boolean
  - `data` object
    - `markdown` string
    - `summary` string, nullable — Summary of the page if `summary` is in `formats`
    - `html` string, nullable — Cleaned HTML of the page if `html` is in `formats`. Removes `<script>`, `<style>`, `<noscript>`, `<meta>`, and `<head>` tags; converts relative URLs to absolute; resolves responsive image `srcset` to the largest version. Respects `onlyMainContent`, `includeTags`, and `excludeTags` filters.
    - `rawHtml` string, nullable — The exact, unmodified HTML as received from the page if `rawHtml` is in `formats`. No cleaning or filtering is applied.
    - `screenshot` string, nullable — Screenshot of the page if `screenshot` is in `formats`. Screenshots expire after 24 hours and can no longer be downloaded.
    - `audio` string, nullable — Signed URL to the extracted MP3 audio file if `audio` is in `formats`. The signed URL expires after 1 hour.
    - `video` string, nullable — Signed URL to the extracted video file if `video` is in `formats`. The signed URL expires after 1 hour.
    - `answer` string, nullable — Natural-language answer to the question supplied via the `question` format. Only present if a `question` format object was included in `formats`.
    - `highlights` string, nullable — Relevant source text selected by the `highlights` format. Only present if a `highlights` format object was included in `formats`.
    - `links` string[] — List of links on the page if `links` is in `formats`
    - `actions` object, nullable — Results of the actions specified in the `actions` parameter. Only present if the `actions` parameter was provided in the request
      - `screenshots` string[] — Screenshot URLs, in the same order as the screenshot actions provided.
      - `scrapes` object[] — Scrape contents, in the same order as the scrape actions provided.
        - `url` string
        - `html` string
      - `javascriptReturns` object[] — JavaScript return values, in the same order as the executeJavascript actions provided.
        - `type` string
        - `value` unknown
      - `pdfs` string[] — PDFs generated, in the same order as the pdf actions provided.
    - `metadata` object
      - `title` union — Title extracted from the page, can be a string or array of strings
        - string
        - string[]
      - `description` union — Description extracted from the page, can be a string or array of strings
        - string
        - string[]
      - `language` union — Language extracted from the page, can be a string or array of strings
        - string
        - string[]
      - `sourceURL` string, uri — The original URL that was requested. May differ from the page's final URL if redirects occurred.
      - `url` string, uri — The final URL of the page after all redirects have been followed.
      - `keywords` union — Keywords extracted from the page, can be a string or array of strings
        - string
        - string[]
      - `ogLocaleAlternate` string[] — Alternative locales for the page
      - `<any other metadata> ` union — Other metadata extracted from HTML, can be a string or array of strings
        - string
        - string[]
      - `statusCode` integer — The status code of the page
      - `numPages` integer — For PDF inputs, the number of pages parsed (capped by the parsers maxPages option).
      - `totalPages` integer — For PDF inputs, the document's true page count before any maxPages capping. Omitted when it cannot be determined; a totalPages greater than numPages indicates the result was truncated.
      - `contentType` string — The content type (MIME type) of the page, e.g. text/html, application/pdf
      - `error` string, nullable — The error message of the page
      - `concurrencyLimited` boolean — Whether this scrape was throttled due to team concurrency limits
      - `concurrencyQueueDurationMs` number — Time in milliseconds the request waited in the concurrency queue. Only present when concurrencyLimited is true.
    - `warning` string, nullable — Can be displayed when using LLM Extraction. Warning message will let you know any issues with the extraction.
    - `changeTracking` object, nullable — Change tracking information if `changeTracking` is in `formats`. Only present when the `changeTracking` format is requested.
      - `previousScrapeAt` string, date-time, nullable — The timestamp of the previous scrape that the current page is being compared against. Null if no previous scrape exists.
      - `changeStatus` 'new' | 'same' | 'changed' | 'removed' — The result of the comparison between the two page versions. 'new' means this page did not exist before, 'same' means content has not changed, 'changed' means content has changed, 'removed' means the page was removed.
      - `visibility` 'visible' | 'hidden' — The visibility of the current page/URL. 'visible' means the URL was discovered through an organic route (links or sitemap), 'hidden' means the URL was discovered through memory from previous crawls.
      - `diff` string, nullable — Git-style diff of changes when using 'git-diff' mode. Only present when the mode is set to 'git-diff'.
      - `json` object, nullable — JSON comparison results when using 'json' mode. Only present when the mode is set to 'json'. This will emit a list of all the keys and their values from the `previous` and `current` scrapes based on the type defined in the `schema`. Example [here](/features/change-tracking)
    - `branding` object, nullable — Branding information extracted from the page if `branding` is in `formats`. Includes colors, fonts, typography, spacing, components, and more.
      - `colorScheme` 'light' | 'dark' — The detected color scheme of the page.
      - `logo` string, nullable — URL of the primary logo.
      - `colors` object, nullable — Brand colors extracted from the page.
        - `primary` string — Primary brand color (hex).
        - `secondary` string — Secondary brand color (hex).
        - `accent` string — Accent color (hex).
        - `background` string — Background color (hex).
        - `textPrimary` string — Primary text color (hex).
        - `textSecondary` string — Secondary text color (hex).
        - `link` string — Link color (hex).
        - `success` string — Success/positive color (hex).
        - `warning` string — Warning color (hex).
        - `error` string — Error/danger color (hex).
      - `fonts` object[], nullable — Array of font families used on the page.
        - `family` string — Font family name.
      - `typography` object, nullable — Detailed typography information.
        - `fontFamilies` object — Font families by role.
          - `primary` string — Primary font family.
          - `heading` string — Heading font family.
          - `code` string — Code/monospace font family.
        - `fontSizes` object — Font sizes for different text levels.
          - `h1` string
          - `h2` string
          - `h3` string
          - `body` string
        - `fontWeights` object — Font weight definitions.
          - `light` integer
          - `regular` integer
          - `medium` integer
          - `bold` integer
        - `lineHeights` object — Line height values for different text types.
          - `heading` string
          - `body` string
      - `spacing` object, nullable — Spacing and layout information.
        - `baseUnit` integer — Base spacing unit in pixels.
        - `borderRadius` string — Default border radius.
        - `padding` object — Padding values.
        - `margins` object — Margin values.
      - `components` object, nullable — UI component styles.
        - `buttonPrimary` object — Primary button styles.
          - `background` string
          - `textColor` string
          - `borderRadius` string
        - `buttonSecondary` object — Secondary button styles.
          - `background` string
          - `textColor` string
          - `borderColor` string
          - `borderRadius` string
        - `input` object — Input field styles.
      - `icons` object, nullable — Icon style information.
      - `images` object, nullable — Brand images.
        - `logo` string — Logo image URL.
        - `favicon` string — Favicon URL.
        - `ogImage` string — Open Graph image URL.
      - `animations` object, nullable — Animation and transition settings.
      - `layout` object, nullable — Layout configuration (grid, header/footer heights).
      - `personality` object, nullable — Brand personality traits (tone, energy, target audience).
    - `product` object, nullable — Product information extracted from the page if `product` is in `formats`. Includes title, brand, category, description, and variants. Pricing, availability, and images live on each variant.
      - `title` string, required — The product title.
      - `brand` string — The product brand or manufacturer.
      - `category` string — The product category, optionally as a breadcrumb path (e.g. 'Electronics > Audio > Headphones').
      - `url` string, required — The canonical URL of the product page.
      - `description` string — The product description.
      - `variants` object[], required — Product variants (e.g. different colors or sizes).
        - `id` string — The variant identifier.
        - `sku` string — The variant SKU.
        - `title` string — The variant title.
        - `values` object — The variant option values (e.g. { "color": "Black" }).
        - `price` object — The current price of the variant.
          - `amount` number, required — The numeric price amount.
          - `currency` string — The ISO 4217 currency code (e.g. 'USD').
          - `formatted` string — The price formatted for display (e.g. '$199.99').
        - `sale` object — Sale/discount information for the variant, present when the variant is discounted.
          - `originalPrice` object, required — The original (pre-discount) price of the variant.
            - `amount` number, required — The numeric price amount.
            - `currency` string — The ISO 4217 currency code (e.g. 'USD').
            - `formatted` string — The price formatted for display (e.g. '$249.99').
        - `availability` object, required — The availability of the variant. Always present on a variant.
          - `inStock` boolean, required — Whether the variant is in stock.
          - `text` string — Human-readable availability text (e.g. 'In Stock').
        - `images` object[] — Variant images.
          - `url` string, required — Image URL.
          - `alt` string — Alternative text for the image.
    - `menu` object, nullable — Menu information extracted from the page if `menu` is in `formats`. Includes the merchant, currency, and a list of sections, where each section carries items with description, images, price, availability, dietary tags, calories, and option groups.
      - `isMenu` boolean, required — Whether the page was identified as a menu.
      - `confidence` number — A confidence score between 0 and 1 for the menu extraction.
      - `merchant` object — The merchant the menu belongs to.
        - `name` string, required — The merchant name.
        - `type` string — The merchant type (e.g. 'restaurant').
      - `currency` string — The ISO 4217 currency code for the menu (e.g. 'USD'), reported only when the page sources it.
      - `sections` object[], required — Menu sections (e.g. 'Appetizers', 'Entrees').
        - `id` string — The section identifier.
        - `name` string, required — The section name.
        - `description` string, nullable — The section description.
        - `items` object[], required — The items in the section.
          - `id` string — The item identifier.
          - `name` string, required — The item name.
          - `description` string, nullable — The item description.
          - `images` object[] — Item images.
            - `url` string, required — Image URL.
            - `alt` string, nullable — Alternative text for the image.
          - `price` object — The price of the item.
            - `amount` number, required — The numeric price amount.
            - `currency` string — The ISO 4217 currency code (e.g. 'USD').
            - `formatted` string — The price formatted for display (e.g. '$7.99').
          - `availability` object — The availability of the item.
            - `inStock` boolean, required — Whether the item is available.
            - `text` string, nullable — Human-readable availability text.
          - `dietary` string[] — Dietary tags for the item (e.g. ['vegetarian']).
          - `calories` number, nullable — The item's calorie count.
          - `optionGroups` object[] — Option/modifier groups for the item.
          - `identifiers` object — Merchant-specific identifiers for the item.
            - `merchantItemId` string — The merchant's own item ID.
          - `url` string, nullable — The canonical URL of the item.
          - `sourceUrl` string, nullable — The URL the item was extracted from.
      - `sourceUrl` string, nullable — The URL the menu was extracted from.

## Other responses

- `402` — Payment required
- `429` — Too many requests
- `500` — Server error

---

[API](https://skmtc.net/firecrawl/apis/firecrawl-api.md) · [All operations](https://skmtc.net/firecrawl/apis/firecrawl-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/firecrawl/firecrawl-api/versions/e350fafb5a2a/schema)
