npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@lxgicstudios/head-check

v1.0.0

Published

Audit HTML head tags for missing elements, wrong order, and SEO issues. Check charset, viewport, title, meta ordering. Detect render-blocking scripts and missing preconnect hints. Auto-fix with --fix flag. Zero dependencies.

Downloads

91

Readme

@lxgicstudios/head-check

npm version license node

Audit your HTML <head> tag for missing elements, wrong ordering, and SEO issues. Checks charset, viewport, title, meta description, Open Graph tags, Twitter Cards, favicon, render-blocking scripts, and preconnect hints. Use --fix to get a corrected version.

Zero dependencies. Just Node.js built-ins.

Install

npm install -g @lxgicstudios/head-check

Or run directly with npx:

npx @lxgicstudios/head-check https://example.com

Usage

# Audit a live URL
head-check https://example.com

# Audit a local HTML file
head-check index.html

# Get a corrected head section
head-check https://example.com --fix

# JSON output for CI/CD
head-check https://example.com --json

Features

  • Checks charset declaration and positioning
  • Validates viewport meta tag configuration
  • Audits title length (30-60 chars recommended)
  • Checks meta description length (120-160 chars recommended)
  • Verifies canonical link tag
  • Validates Open Graph tags (og:title, og:description, og:image, og:url)
  • Checks Twitter Card meta tags
  • Detects missing favicon declaration
  • Flags render-blocking scripts without async/defer
  • Suggests preconnect hints for external domains
  • Checks html lang attribute
  • Detects duplicate tags
  • Scores your head section out of 100
  • Auto-fix mode reorders and adds missing tags
  • Works with live URLs and local HTML files
  • Zero external dependencies

Options

| Option | Description | Default | |--------|-------------|---------| | --fix | Output a corrected <head> section | false | | --json | Output results as JSON | false | | --timeout <ms> | Request timeout in milliseconds | 10000 | | --help | Show help message | |

What It Checks

| Check | Severity | Description | |-------|----------|-------------| | Charset | Error | Must be present and first in head | | Viewport | Error | Required for mobile rendering | | Title | Error | Required, 30-60 chars recommended | | Description | Warning | 120-160 chars recommended | | Canonical | Warning | Prevents duplicate content issues | | Open Graph | Warning | Needed for social sharing | | Twitter Card | Info | Falls back to OG but explicit is better | | Favicon | Warning | Declare it or browsers guess | | Blocking Scripts | Warning | Use async or defer | | Preconnect | Info | Speed up third-party connections | | Language | Warning | Set lang on html tag |

Example Output

head-check v1.0.0

Fetching https://example.com...

Score: 85/100

Charset
  ✔ charset="utf-8" is present and correctly positioned.

Viewport
  ✔ Viewport is properly configured.

Title
  ✔ Title is good (42 chars): "Example Domain - Your Site Title"

Description
  ⚠ Missing meta description. Search engines may generate one.

Open Graph
  ⚠ Missing OG tags: og:title, og:description, og:image, og:url.

Summary: 0 errors | 2 warnings | 3 passed

License

MIT - LXGIC Studios