puerkitobio/goquery

A little like that j-thing, only in Go.

View on GitHub ↗Jump to charts ↓

Summary Information

Updated 17 minutes ago
Added to GitGenius on September 3rd, 2026
Created on August 29th, 2012
Open Issues & Pull Requests: 6 (-1)
GitHub issues: Enabled
Number of forks: 937
Total Stargazers: 14,986 (+0)
Total Subscribers: 243 (+0)

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Issue API getrepoissuespagesummary failed: 429 Rate limit exceeded. Please try again later.

Detailed Description

goquery is an HTML parsing library for Go that provides a jQuery-like syntax for selecting and manipulating HTML documents.

The library solves the problem of making HTML parsing in Go more accessible by adopting jQuery's familiar API and chainable interface. It wraps Go's built-in net/html package and the cascadia CSS selector library, allowing developers to query and traverse HTML documents using CSS selectors and method chaining patterns they may already know from jQuery. However, because the underlying net/html parser works with nodes rather than a full DOM tree, stateful manipulation functions like height(), css(), and detach() are not available. The library also requires UTF-8 encoded input, placing responsibility on the caller to handle encoding conversion if needed.

Developers should choose goquery when they need to parse and query HTML in Go and want an intuitive, jQuery-inspired API. It suits projects that require CSS selector-based HTML traversal without needing advanced DOM manipulation capabilities. The library is particularly valuable for developers familiar with jQuery who want to avoid learning a completely new query syntax.

The project maintains a stable API with no breaking changes expected. Development is actively tested against the latest versions of Go, with the codebase regularly updated to support current language features including recent additions like function-based iterators and generics. The project includes comprehensive benchmarking infrastructure and maintains unit test coverage.