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

guessit-js

v3.9.0

Published

Extract metadata (title, year, season, episode, codec, language, etc.) from media filenames — TypeScript port of Python guessit

Readme

guessit-js

Extract metadata (title, year, season, episode, codec, language, etc.) from media filenames — TypeScript port of Python guessit.

npm version License: LGPL-3.0

Live Demo · API Docs · WASM Test

Features

  • 100% compatibility with Python guessit (1035/1035 tests passing)
  • 3.5x faster than Python (6.87ms vs 23.86ms per parse)
  • 40+ properties detected: title, year, season, episode, resolution, codec, language, and more
  • Single dependency (rebulk-js)
  • Dual format: ESM and CommonJS
  • TypeScript: full type definitions included
  • WASM: runs in any WASI-compatible runtime

Install

npm install guessit-js

Usage

import { guessit } from 'guessit-js';

const result = guessit('The.Dark.Knight.2008.1080p.BluRay.x264-GROUP.mkv');
// {
//   title: 'The Dark Knight',
//   year: 2008,
//   screen_size: '1080p',
//   source: 'Blu-ray',
//   video_codec: 'H.264',
//   release_group: 'GROUP',
//   container: 'mkv',
//   type: 'movie'
// }

CommonJS

const { guessit } = require('guessit-js');
const result = guessit('Breaking.Bad.S01E02.720p.BluRay.x264-DEMAND.mkv');
console.log(result.title);   // 'Breaking Bad'
console.log(result.season);  // 1
console.log(result.episode); // 2

Options

guessit('file.mkv', { type: 'episode' });
guessit('my 720p show S01E02', { expected_title: ['my 720p show'] });
guessit('file.mkv', { allowed_languages: ['en', 'fr'] });
guessit('file.mkv', { excludes: ['release_group'] });

Detected Properties

| Category | Properties | |----------|-----------| | Title | title, alternative_title, episode_title | | Episode | season, episode, episode_details, episode_count, season_count, absolute_episode, disc, part | | Date | year, date | | Video | screen_size, aspect_ratio, frame_rate, video_codec, video_profile, color_depth | | Audio | audio_codec, audio_profile, audio_channels, audio_bit_rate | | Source | source, streaming_service | | Release | release_group, edition, other, proper_count | | File | container, mimetype, size, crc32, uuid | | Metadata | language, subtitle_language, country, type |

REST API

npm start  # port 3847

curl "http://localhost:3847/api/guessit?filename=Movie.2024.1080p.mkv"

WASM

Compiles to WebAssembly via Javy (QuickJS engine). For non-JS environments (Rust, Go, C++, edge compute).

npm run wasm
echo '{"filename":"Movie.2024.1080p.mkv"}' | wasmtime wasm/guessit.wasm

Performance

| Runtime | ms/parse | vs Python | |---------|----------|-----------| | Python 3.8 (guessit 3.8.0) | 23.86 ms | baseline | | Node.js 22 (guessit-js) | 6.87 ms | 3.5x faster | | Browser (IIFE bundle) | ~2-3 ms | ~10x faster |

License

LGPL-3.0