Web scraping is the automated extraction of data from websites. A program fetches a page, reads its HTML or rendered DOM, and pulls out specific fields such as a price, a job title, a headline, or a feature list, converting unstructured web content into structured rows a database or spreadsheet can hold. It exists because most of the web is published for human eyes, not machines: the data is visible on the page but not offered as a clean feed, so scraping reconstructs the structure the site never exposed.
There is no single inventor or founding paper for web scraping. The practice grew alongside the early web. The first web robot, the World Wide Web Wanderer, appeared in 1993 to measure the web's size, and JumpStation the same year became the first crawler-based search engine, establishing the crawl-and-parse techniques scraping later built on. Tooling matured with libraries like Python's BeautifulSoup, released in 2004, which made HTML parsing routine. In parallel, platforms such as Salesforce and eBay began offering official APIs around 2000 specifically so developers would not have to scrape their HTML.
Today scraping underpins price comparison, search indexing, market research, and competitive intelligence. Any workflow that needs data from sites that publish it on a page but not through an API tends to reach for scraping. Competitor-tracking platforms are a clear case: they fetch a fixed set of competitor pages, parse them into structured fields, and compare each snapshot against the last to surface what changed.
How web scraping works
A scrape runs in stages. First a request fetches the page, returning its raw HTML. For static pages that is enough, and a parser walks the markup and pulls the target fields by their tags, classes, or XPath. Many sites, though, build their content with JavaScript after the initial HTML loads, so the data a user sees is not present in the raw response. Those sites require a headless browser such as Selenium or Playwright that renders the page, executes its scripts, and exposes the finished DOM before extraction happens.
Once the relevant elements are located, the scraper maps them to named fields and emits structured output as CSV, JSON, or database rows. Two roles are often separated in a pipeline. A crawler follows links to discover which URLs exist; a scraper parses each known page to pull specific values. Some tools do both, others just one. A price-monitoring job, for example, may skip discovery entirely and scrape a fixed list of URLs, while a search indexer leans heavily on crawling to find pages first.
Web scraping vs. web crawling
The two terms are routinely conflated, but they answer different questions. Crawling answers what exists: it starts from seed URLs, follows hyperlinks, and builds a catalog of pages, which is how search engines map a site. Scraping answers what a page says: it takes a known URL and extracts specific data fields from its markup.
In practice the two chain together, crawling to discover URLs then scraping each one, which is why tools and vendors often bundle them. But they are distinct steps with distinct designs. A crawler cares about link graphs, coverage, and avoiding traps; a scraper cares about selectors, field mapping, and handling pages whose structure shifts. Competitive-intelligence pipelines usually weight toward targeted scraping of a curated URL set rather than open-ended crawling, because the pages that matter, such as a rival's pricing, careers, and blog pages, are already known and only need to be re-read on a schedule.
How competitive intelligence teams use scraping
Web scraping is the collection layer beneath most competitor-tracking work. The pattern is consistent: fetch a competitor's page, parse the HTML or rendered DOM into structured fields, store that snapshot, then diff it against the previous one. A change in a parsed price, a new job posting, an edited headline, or an added plan tier becomes a signal a team can act on. Because the output is structured rather than a screenshot, the comparison can be field-level and precise instead of a vague visual sense that something moved.
The scope is usually narrow by design. Rather than crawling an entire competitor domain, CI tools scrape a fixed set of high-value URLs, namely pricing, product, careers, press, and blog, on a recurring interval. That keeps the pipeline focused, makes diffs meaningful, and limits load on the target site. It also concentrates parsing effort on a small number of page templates whose structure the tool can learn and maintain.
Legal and ethical boundaries
Scraping's legal status is context-dependent and, in places, unsettled. The most cited U.S. case, hiQ Labs v. LinkedIn, saw the Ninth Circuit rule in 2019 that scraping publicly available, non-password-protected data did not violate the Computer Fraud and Abuse Act. The Supreme Court remanded it in 2021 after a separate ruling narrowed the CFAA, and the dispute ended in settlement rather than a definitive high-court precedent on scraping.
The practitioner consensus is more stable than the case law. Scraping public, non-logged-in data carries comparatively low legal risk. Risk rises materially when scraping reaches behind logins or paywalls, collects personal data or copyrighted content, or violates a site's Terms of Service or robots.txt. For a CI vendor running its own collection jobs, staying in the lower-risk zone means respecting robots.txt and Terms of Service, avoiding logged-in or personal content, and rate-limiting requests so gathering intelligence does not strain the sites being watched.