wait
parameter to your request, ZenRows pauses for the specified duration (in milliseconds) after the page initially loads, ensuring that slow-loading elements, animations, and dynamically generated content have time to appear before the HTML is extracted. The maximum wait
value acceptable is 30 seconds (30,000 milliseconds).
js_render=true
to function, as it operates within the browser environment during JavaScript rendering.wait
parameter with a value in milliseconds to your JavaScript rendering request:
Issue | Cause | Solution |
---|---|---|
Content still missing | Wait time too short | Increase wait duration incrementally |
Inconsistent results | Variable loading times | Use longer wait time, use wait_for , or implement retry logic |
REQS004 | Invalid value provided for wait parameter; value is too big (REQS004) | Keep wait under 30 seconds total or use wait_for |
Unnecessary delays | Fixed wait for fast-loading content | Use wait_for parameter for dynamic waiting |
Check browser behavior manually
Increase wait time gradually
Switch to the element-specific waiting (`wait_for`)
wait
parameter doesn’t increase the request cost. You pay the JavaScript Render (5 times the standard price) regardless of the wait value you choose.
What's the difference between wait and wait_for parameters?
wait
parameter introduces a fixed delay in milliseconds, while wait_for
waits for a specific element to appear on the page. Use wait
when you know content takes a particular amount of time to load, and wait_for
when you want to wait for specific elements to appear.Can I use wait without js_render=true?
wait
parameter only works with JavaScript rendering enabled. Without js_render=true
, the wait parameter will be ignored since there’s no browser environment to pause within.How do I know if my wait time is too short or too long?
Should I use the same wait time for all pages on a website?
Can I use wait with other features?
wait
parameter works perfectly with any other feature.What happens if I use both wait and wait_for?
wait
and wait_for
, the wait_for
parameter takes precedence and overrides the wait
parameter.