Skip to content

Introduction to google-sr-selectors

Set of html selectors for parsing google search results with jquery like modules (ex: cheerio).

🌟 Show Your Support!

If you like the project, please give it a star on Github & Codeberg to express your support!

🕵️‍♂️ Note

Please note that the included selectors are intended for the non-Javascript version of Google Search page. These were obtained by appending &gbv=1 to the regular query link.

ex: (disable javascript, else it will redirect): query nodejs

Installation

NPM license

npm downloads

sh
npm i google-sr-selectors
sh
pnpm add google-sr-selectors
sh
yarn add google-sr-selectors

What are selectors?

Selectors form the backbone of packages like google-sr. These are predefined strings that outline the structure of specific HTML code representing the desired value. By utilizing selectors, we gain the ability to parse the HTML and precisely extract the intended information.

This package exports the selectors used to extract search result values from, google html page data we receive. Offered for purposes of contributors and other developers interested in parsing raw google search html.

WARNING

Google can update its HTML structure periodically, which could potentially disrupt the functionality of the package. While we do run a github action to test the package periodically, we may take time to patch package.

If you suspect that Google has updated all or some selectors and we have not yet patched the package, please create a github issue.

License

This repository and the code inside it is licensed under the Apache-2.0 License. Read LICENSE for more information.