How to Capture Screenshots of Indian Job Listing Websites with Selenium
Capture a job listing’s visible browser view or a selected element with Selenium in Python. Learn about waits, full-page limits, site policies, and an API alternative.
Use Selenium’s Python driver.save_screenshot() after opening a job listing to save a PNG of the current browser view. To capture just one listing card or another region, locate it and call element.screenshot(). The ordinary viewport method is not documented as a universal full-page screenshot of the entire scrollable document.
The examples below use https://example.com/job-listing and a generic selector. Replace them with a page and selector you are authorized to access and have confirmed in that page’s markup. The research behind this guide did not test these examples against an Indian job board or establish any board-specific selectors.
1. Install Selenium and a browser
Install Selenium in the Python environment where the script will run:
python -m pip install selenium
You also need a browser supported by your Selenium setup, such as Chrome. Selenium’s browser and driver setup depends on your local environment; consult the official Selenium documentation for current setup guidance. The code below uses Selenium’s documented Python API.
2. Capture the visible browser view
save_screenshot(path) saves the current browsing context as a PNG. This complete example creates an output directory, navigates to a page, waits for the document to load, saves a viewport screenshot, and always closes the browser:
from pathlib import Path
from selenium import webdriver
from selenium.webdriver.support.ui import WebDriverWait
url = "https://example.com/job-listing"
output = Path("screenshots")
output.mkdir(parents=True, exist_ok=True)
options = webdriver.ChromeOptions()
# Uncomment for a browser without a visible window:
# options.add_argument("--headless=new")
driver = webdriver.Chrome(options=options)
try:
driver.set_window_size(1440, 1000)
driver.get(url)
# Wait for the browser's document load state. A page-specific wait is
# usually better when the listing content is rendered asynchronously.
WebDriverWait(driver, 20).until(
lambda d: d.execute_script("return document.readyState") == "complete"
)
saved = driver.save_screenshot(str(output / "listing-viewport.png"))
if not saved:
raise RuntimeError("Selenium did not save the screenshot")
finally:
driver.quit()
The explicit window size makes the viewport dimensions more repeatable, but it does not guarantee identical rendering across operating systems, browser versions, fonts, or device scale settings. Choose dimensions that suit your use case.
3. Wait for the listing content, then capture
A completed document load does not guarantee that a job card rendered: many sites fill parts of the page later. Use a condition tied to the content you need. Do not assume that one selector works across job boards; inspect the page you are authorized to automate and choose a selector that actually identifies the desired content.
from pathlib import Path
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.support.ui import WebDriverWait
url = "https://example.com/job-listing"
listing_selector = "main" # Replace with a verified selector for this page.
output = Path("screenshots/listing-ready.png")
output.parent.mkdir(parents=True, exist_ok=True)
driver = webdriver.Chrome()
try:
driver.get(url)
listing = WebDriverWait(driver, 30).until(
EC.visibility_of_element_located((By.CSS_SELECTOR, listing_selector))
)
driver.save_screenshot(str(output))
finally:
driver.quit()
For dynamically updated pages, wait for the specific listing card or a meaningful change in its content. A fixed sleep can be useful for a known delay, but it is less reliable: it may wait too long on fast pages and still be too short on slow ones.
4. Capture one listing element
If you need a single job card instead of the whole visible browser view, capture the located element. Selenium documents element screenshots as a separate operation.
from pathlib import Path
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.support.ui import WebDriverWait
url = "https://example.com/job-listing"
card_selector = "article" # Replace with a selector verified on this page.
output = Path("screenshots/job-card.png")
output.parent.mkdir(parents=True, exist_ok=True)
driver = webdriver.Chrome()
try:
driver.get(url)
card = WebDriverWait(driver, 30).until(
EC.visibility_of_element_located((By.CSS_SELECTOR, card_selector))
)
if not card.screenshot(str(output)):
raise RuntimeError("Selenium did not save the element screenshot")
finally:
driver.quit()
An element screenshot is useful when the evidence or image should be limited to one card or page region. It is not a screenshot of the full document. If the target is below the fold, Selenium may scroll it into view as part of element screenshot handling; check the resulting framing for your page.
5. Save screenshot data as a file, bytes, or Base64
The Python API also exposes screenshot data directly. Use these forms when you need to pass the image to another part of your program instead of writing it immediately to a path.
# PNG file
ok = driver.save_screenshot("listing.png")
# PNG bytes
png_bytes = driver.get_screenshot_as_png()
with open("listing.png", "wb") as f:
f.write(png_bytes)
# Base64-encoded PNG string
png_base64 = driver.get_screenshot_as_base64()
These methods represent the current screenshot context; choosing bytes or Base64 does not make a viewport capture cover the entire scrollable page.
6. What about a full-page screenshot?
If by “full page” you mean the entire scrollable document, do not label driver.save_screenshot() as a guaranteed full-page capture. The Selenium documentation cited here describes that method as capturing the current browsing context, and documents element screenshots and print-to-PDF separately. It does not establish a universal full-document PNG method through the ordinary call.
For a long-page image, select and validate an approach for the exact browser and driver you use, such as a browser-specific full-page facility or stitching viewport captures. Test the result on the target page: sticky headers may repeat, lazy-loaded results may not exist until scrolled into view, and content may change between captures. The research for this article did not verify one universal full-page technique across browsers.
7. Check access rules before automating a job board
Being able to render a page with Selenium does not establish permission to automate access or reuse its contents. Check the current terms and policies for the particular site, account, and purpose. Do not work around login, rate, bot, or other access controls.
- LinkedIn: its policy says third-party software used to scrape or automate LinkedIn is not permitted, and discusses scraping or copying service content and bypassing access controls. The policy page was marked as last updated two years before the research date, so check its current wording before relying on it. LinkedIn User Agreement.
- Indeed India: its job seeker guidance says not to use third-party bots or other automated tools to apply for jobs. That is a stated restriction on application automation; it should not be broadened into a claim about every screenshot taken during ordinary browsing. Its terms say access and use are governed by the terms in effect. Indeed India legal and policy information.
- Naukri and other boards: this research did not verify Naukri’s current terms or whether a particular screenshot use is allowed. Review the current terms and obtain authorization where needed.
Selenium’s rendering capability and a site’s permission rules are separate questions. A screenshot should not be used to evade a site restriction.
8. Or skip the browser setup
ScreenshotNeo is a website screenshot API and MCP server from ScreenshotNeo. One GET request can return an image or PDF. See the ScreenshotNeo API documentation for options and response details.
curl -G "https://api.screenshotneo.com/v1/shot" \
-d access_key=YOUR_API_KEY \
--data-urlencode url=https://example.com/job-listing \
-o job-listing.webp
Cookie and consent banners are accepted before capture, and 60+ known consent platforms, newsletter popups, and chat widgets are removed; each step can be turned off. Bot checks, blank pages, timeouts, failed loads, and cache hits are not billed, and the response indicates the page verdict and billing status in headers. An MCP server gives AI agents tools to take screenshots, get page information, and capture PDFs. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 shots.
Sign up for 1,000 free screenshots a month, with no card required.
9. Troubleshooting
| Symptom | Likely cause | What to do |
|---|---|---|
Unable to obtain driver or browser startup failure |
The browser or driver setup is missing, incompatible, or unavailable in the execution environment. | Confirm a supported browser is installed and follow current Selenium setup documentation. Check the error details for the browser and driver versions. |
| Screenshot is blank or misses the listing | The capture happened before the relevant content rendered, or the page requires an additional authorized interaction. | Wait for a page-specific visible element or content change. Do not try to bypass an access control. |
Element lookup raises NoSuchElementException |
The example selector does not match the page, or the element has not appeared yet. | Inspect the page you are authorized to access, replace the generic selector, and wait for the element to exist or become visible. |
| Element lookup times out | The selector is wrong, the element is not visible in the current state, or the expected content did not load. | Check the selector and page state, and confirm the expected content is available without automating prohibited access. |
| Only the visible portion of a long page appears | save_screenshot() captures the current context rather than promising a full-document image. |
Use and validate a browser-specific full-page method or a stitching workflow; account for lazy content and sticky elements. |
| Output file is missing | The parent directory does not exist, the process lacks write access, or the screenshot call returned false. | Create the directory, check filesystem permissions, and verify the boolean result of save_screenshot(). |
| Screenshot differs between runs | Viewport size, browser environment, fonts, dynamic content, or load timing changed. | Set a consistent window size and wait for stable page content. Treat dynamic listing changes as expected unless the page is known to be static. |
10. Reliability, performance, and cost
For repeated captures, close the driver in a finally block so browser processes are cleaned up even if navigation or capture fails. Use explicit waits for the content you need. Browser startup and page rendering are part of the work, so a screenshot is not instantaneous; unnecessary fixed waits and oversized pages add time and resource use. A local Selenium workflow has no per-shot API charge, but it still uses compute, browser resources, and network access. Site terms and authorization constraints continue to apply.
When capture volume or browser setup is the concern, an API can avoid managing a browser process in your script. ScreenshotNeo’s published plans are Free (1,000 shots/month), Starter ($5 for 3,000), Growth ($15 for 15,000), Pro ($39 for 60,000), Scale ($99 for 250,000), and Business ($249 for 1,000,000); yearly billing gives two months free, and every feature is on every plan. Use its billing and usage details to choose a plan for your workload. These prices and limits are ScreenshotNeo product facts, not Selenium pricing.
11. Frequently asked questions
Does Selenium save screenshots as PNG?
Yes. The documented Python screenshot methods save or return PNG screenshot data.
Can I use Selenium to take screenshots of job listings without logging in?
That depends on the site’s access rules and the page. Use only an authorized access context and follow the current terms; this guide does not establish permission for any particular board.
Does an element screenshot include the whole job description?
It captures the selected element. Whether that element contains all the text you need depends on the page structure and whether the content has loaded.
Is there a universal selector for Indian job cards?
No selector is established here as universal. Inspect the specific page and use a selector confirmed for that page.


