htmlq is a command-line tool for extracting content from HTML using CSS selectors, functioning as the HTML equivalent of jq. Written in Rust, it lets you pipe HTML through CSS selectors to extract text, attributes, and structured content directly from the terminal.
Scanned 6/8/2026
Install via CLI
openskills install agentskillexchange/skills---
name: "htmlq Command-Line HTML Content Extractor with CSS Selectors"
slug: "htmlq-command-line-html-content-extractor-css-selectors"
description: "htmlq is a command-line tool for extracting content from HTML using CSS selectors, functioning as the HTML equivalent of jq. Written in Rust, it lets you pipe HTML through CSS selectors to extract text, attributes, and structured content directly from the terminal."
github_stars: 7514
verification: "security_reviewed"
source: "https://github.com/mgdm/htmlq"
author: "Michael Maclean"
publisher_type: "Individual Developer"
category: "Data Extraction & Transformation"
framework: "Multi-Framework"
tool_ecosystem:
github_repo: "mgdm/htmlq"
github_stars: 7514
---
# htmlq Command-Line HTML Content Extractor with CSS Selectors
htmlq is a command-line tool for extracting content from HTML using CSS selectors, functioning as the HTML equivalent of jq. Written in Rust, it lets you pipe HTML through CSS selectors to extract text, attributes, and structured content directly from the terminal.
## Prerequisites
Rust (cargo) or Homebrew
## Installation
Use the upstream install or setup path that matches your environment:
- cargo install htmlq
- brew install htmlq
Requirements and caveats from upstream:
- ### Remove a node before output
Basic usage or getting-started notes:
- ### [Cargo](https://crates.io/crates/htmlq)
- sh
- ### [FreeBSD pkg](https://www.freshports.org/textproc/htmlq)
- Source: https://github.com/mgdm/htmlq
- Extracted from upstream docs: https://raw.githubusercontent.com/mgdm/htmlq/HEAD/README.md
## Documentation
- https://github.com/mgdm/htmlq#readme
## Source
- [Agent Skill Exchange](https://agentskillexchange.com/skills/htmlq-command-line-html-content-extractor-css-selectors/)
No comments yet. Be the first to comment!
Ultra-compressed communication mode. Cuts token usage ~75% by speaking like caveman while keeping full technical accuracy. Supports intensity levels: lite, full (default), ultra, wenyan-lite, wenyan-full, wenyan-ultra. Use when user says "caveman mode", "talk like caveman", "use caveman", "less tokens", "be brief", or invokes /caveman. Also auto-triggers when token efficiency is requested.