PHPackages                             alc/domq - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [CLI &amp; Console](/categories/cli)
4. /
5. alc/domq

ActiveLibrary[CLI &amp; Console](/categories/cli)

alc/domq
========

Command line XML/HTML DOM Parser

v1.0.0(9y ago)125MITPHPPHP &gt;=5.3.0

Since Dec 7Pushed 9y ago1 watchersCompare

[ Source](https://github.com/chemel/domq)[ Packagist](https://packagist.org/packages/alc/domq)[ Docs](https://github.com/chemel/domq)[ RSS](/packages/alc-domq/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (2)Versions (5)Used By (0)

domq
====

[](#domq)

Command line HTML DOM Parser

Install globaly via composer
----------------------------

[](#install-globaly-via-composer)

```
composer global require alc/domq

# Make sure you have export PATH in your ~/bashrc
export PATH=~/.config/composer/vendor/bin:$PATH
```

Usage
-----

[](#usage)

```
# Query Hacker News Titles
domq https://news.ycombinator.com/ a.storylink innertext

# Query Hacker News Urls
domq https://news.ycombinator.com/ a.storylink getAttribute href

# Query Google Urls
domq https://www.google.fr/search?q=github 'h3.r a' attr href

# Query a local file
domq sitemap.xml 'sitemap loc' innertext

# Query a list of urls
domq urls=urls.txt 'h1.entry-title a' attr href

# Parse from stdin
curl -s http://blog.chemel.fr/sitemap.xml | domq stdin loc innertext

# Piping
domq http://blog.chemel.fr/sitemap.xml loc | domq urls=- loc

# Show help
domq --help
```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

4

Last Release

3446d ago

Major Versions

v0.5.0 → 1.0.x-dev2016-12-07

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/2664215?v=4)[Alexis CHEMEL](/maintainers/chemel)[@chemel](https://github.com/chemel)

---

Top Contributors

[![chemel](https://avatars.githubusercontent.com/u/2664215?v=4)](https://github.com/chemel "chemel (15 commits)")

---

Tags

cliparser

### Embed Badge

![Health badge](/badges/alc-domq/health.svg)

```
[![Health](https://phpackages.com/badges/alc-domq/health.svg)](https://phpackages.com/packages/alc-domq)
```

###  Alternatives

[symfony/console

Eases the creation of beautiful and testable command line interfaces

9.8k1.1B11.3k](/packages/symfony-console)[nunomaduro/collision

Cli error handling for console/command-line PHP applications.

4.6k331.8M8.5k](/packages/nunomaduro-collision)[nunomaduro/termwind

It's like Tailwind CSS, but for the console.

2.5k239.8M286](/packages/nunomaduro-termwind)[wp-cli/wp-cli

WP-CLI framework

5.0k17.2M320](/packages/wp-cli-wp-cli)[wp-cli/php-cli-tools

Console utilities for PHP

68325.0M367](/packages/wp-cli-php-cli-tools)[kzykhys/ciconia

The Markdown parser for PHP5.4

35366.7k13](/packages/kzykhys-ciconia)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
