Get the Text and Title of a Single Web Page
Created by
Radosław Szal
One URL in, one clean record out: title and visible text, rendered in a real browser so JavaScript pages work. No crawling. $0.003 per page.
Python Web Scraper — Playwright, Any Websiteeszetael_lab/reliable-playwright-scraper
URL
Title
Text
Text cut at 5000
+1 fieldTextNumberBooleanListObject
Input
Start URLs(required)
url:https://docs.python.org/3/library/index.html
Page function:async def page_function(page, context, request):
body = await page.inner_text('body')
return {
'url': request.url,
'title': await page.title(),
'text': body[:5000],
'textTruncated': len(body) > 5000,
}
Max pages to crawl:1
Max concurrency:5
Request timeout (seconds):90
Wait until:load
Respect robots.txt:true
Proxy configuration
Block images, fonts and media:true
Session handling:auto
Max items:1
Deliver records from pages that returned nothing:false
Output fields
URL
Title
Text
Text cut at 5000
Fully loaded
Sign up on Apify01
Create your Apify account to access the Python Web Scraper — Playwright, Any Website.
Start the run02
The Actor will start running based on the input automatically.
Receive the output03
Monitor the progress in real-time. You will be notified as soon as your dataset is complete and ready for review.
Integrate into your workflow04
The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow.
