Skip to main content
JavaScript rendering enables full browser execution to capture dynamically loaded content, handle user interactions, and process JavaScript-heavy websites. Control rendering behavior with advanced options for timeout, iframe handling, and load detection.

When to use

Use JavaScript rendering when you need to:
  • Load dynamic content: Capture content loaded via AJAX or fetch requests
  • Execute JavaScript: Process sites that require JS for content display
  • Handle SPAs: Extract data from Single Page Applications (React, Vue, Angular)
  • Wait for interactions: Capture DOM state after user actions
  • See final state: Get the page as users see it, not raw HTML

Parameters

render
boolean | 'auto'
default:"false"
Turn JavaScript rendering on or off. When enabled, the page loads in a real browser that executes JavaScript, just like when you visit it yourself.When to enable:
  • Single Page Applications (React, Vue, Angular)
  • Content loaded via AJAX or fetch
  • Sites that need JavaScript to display content
  • When you need the page as users see it
When to keep disabled (faster, cheaper):
  • Static HTML pages
  • Simple websites without JavaScript
  • When raw HTML is sufficient
Auto mode: Set render: "auto" to let Nimble decide per request. The optimization engine starts with the fastest, cheapest configuration and automatically escalates through more capable driver configurations (including full rendering and stealth) until the request succeeds for the target domain.Note: Rendering requires vx8 or vx10. The vx6 driver doesn’t support rendering.
Example:
Example (automatic driver selection):
auto_driver_configuration
object
Customize how automatic driver selection escalates. Maps driver configuration names to the number of attempts to spend on each before advancing to the next one (0 skips it). The key order defines the escalation order.Providing this parameter automatically opts the request into render: "auto" — you don’t need to set render as well.Available configuration names:
  • vx6-fast - Plain HTTP request, no browser session (fastest)
  • vx6-stealth - HTTP request with a persistent browser session
  • vx8 - Headless browser rendering
  • vx8-pro - Headful browser rendering
  • vx10 - Stealth headless browser rendering
  • vx10-pro - Stealth browser rendering with a persistent session (most effective)
Rules:
  • Attempts per configuration: 0-10
  • At least one configuration must have attempts > 0
  • If a specific driver is also set, it wins and auto_driver_configuration is ignored
Example:
This tries a plain HTTP request once, then headless rendering up to 3 times, then maximum stealth up to 2 times.
render_options
object
Fine-tune how the browser waits and loads the page. Only applies when render: true.Available options:
  • render_type - When to consider the page “loaded”
    • load (default) - Wait for the standard page load event - good for most pages
    • domready - Stop as soon as HTML is ready, before images load - fastest option
    • idle2 - Wait until only 2 or fewer network requests in the last 500ms - good for dynamic content
    • idle0 - Wait until zero network activity for 500ms - most thorough, slowest
  • timeout - Maximum wait time in milliseconds (default: 30,000)
    • How long to wait before giving up
  • include_iframes - Whether to load content inside iframes (default: false)
    • Enable for embedded videos, widgets, or important iframe content
  • blocked_domains - List of domains to block during loading
    • Great for blocking ads, analytics, or tracking scripts
    • Makes pages load faster and cleaner
Example:

Usage

Enable basic rendering

Set render: true to enable JavaScript execution:
When render: false (default), the API returns the raw HTML without JavaScript execution, suitable for static pages.

Automatic driver selection

Set render: "auto" to let Nimble pick the optimal configuration per domain. The engine starts cheap and fast, and escalates to rendering and stealth only when needed:
To control how the engine escalates, provide auto_driver_configuration with the configurations to try and how many attempts to spend on each:
auto_driver_configuration implies render: "auto", so you don’t need to set both. If you also set a specific driver, the driver wins and auto_driver_configuration is ignored.

Dynamic content loading

Wait for AJAX-loaded content:

Iframe content extraction

Include iframe content in extraction:

Block unnecessary resources

Improve performance by blocking ads and tracking:

Fast rendering for simple sites

Use DOMContentLoaded for faster responses:

Combining with browser actions

Rendering works seamlessly with browser actions:

Best practices

Choose the right render type

Use load for standard pages:
Use domready for speed:
Use idle2 for dynamic content:
Use idle0 for complete loading:

Optimize timeout settings

Set appropriate timeouts:

Block unnecessary domains

Common domains to block:
Benefits of blocking:
  • Faster page loads
  • Lower bandwidth usage
  • Reduced detection risk
  • Cleaner HTML output

Handle iframes carefully

Enable only when needed:

Combine with network capture

Monitor and capture API calls during rendering:

Performance optimization

Choose the minimal driver:
Monitor execution time:

When to skip rendering

Use non-rendering (vx6) when:
  • Static content: HTML already contains all data
  • API endpoints: Fetching JSON directly
  • High throughput needed: Rendering is slower
  • Simple pages: No JavaScript required
  • Cost optimization: Non-rendering is cheaper