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

@isdisposable/js

v1.0.5

Published

Detect disposable and temporary email addresses. Open source, zero dependencies, 160k+ domains.

Readme

@isdisposable/js

npm version npm downloads license bundle size

Stop fake signups. One line of code.

Open-source email validation that catches disposable emails before they waste your time. 161,000+ domains. Zero dependencies.

Install

npm install @isdisposable/js

Quick Start

import { isDisposable } from '@isdisposable/js';

isDisposable('[email protected]'); // true
isDisposable('[email protected]');      // false

That's it. Synchronous, offline, zero config.

Bulk Check

import { isDisposableBulk } from '@isdisposable/js';

isDisposableBulk(['[email protected]', '[email protected]']);
// [true, false]

Why isDisposable?

| Feature | isDisposable | mailchecker | disposable-email-domains | |---------|-------------|-------------|--------------------------| | Domains | 161,000+ | 55,000 | 5,000 | | Simple boolean API | Yes | Yes | No (just a list) | | Zero dependencies | Yes | No | N/A | | TypeScript | Yes | Partial | N/A | | Hosted API with scoring | Yes | No | No | | Actively maintained | Yes | Sporadic | Sporadic |

Framework Examples

Next.js Server Action

'use server';
import { isDisposable } from '@isdisposable/js';

export async function signup(formData: FormData) {
  const email = formData.get('email') as string;

  if (isDisposable(email)) {
    return { error: 'Please use a real email address' };
  }

  // Continue with signup...
}

Express Middleware

import express from 'express';
import { isDisposable } from '@isdisposable/js';

const app = express();
app.use(express.json());

app.post('/signup', (req, res, next) => {
  if (isDisposable(req.body.email)) {
    return res.status(400).json({ error: 'Please use a real email address' });
  }
  next();
});

Better Auth Integration

import { betterAuth } from 'better-auth';
import { isDisposable } from '@isdisposable/js';

export const auth = betterAuth({
  databaseHooks: {
    user: {
      create: {
        before: async (user) => {
          if (isDisposable(user.email)) {
            return false; // Block signup
          }
          return user;
        },
      },
    },
  },
});

Supabase Edge Function

import { isDisposable } from '@isdisposable/js';

Deno.serve(async (req) => {
  const { email } = await req.json();

  if (isDisposable(email)) {
    return new Response(
      JSON.stringify({ error: 'Disposable emails not allowed' }),
      { status: 400, headers: { 'Content-Type': 'application/json' } }
    );
  }

  return new Response(JSON.stringify({ ok: true }));
});

API Mode (Enhanced Detection)

For real-time DNS/MX checks, risk scoring (0-100), and domain age analysis, use the hosted API:

import { createIsDisposable } from '@isdisposable/js';

const checker = createIsDisposable({
  apiKey: 'isd_live_xxxxx', // Get one at https://isdisposable.com
});

const result = await checker.check('[email protected]');
// {
//   disposable: true,
//   email: "[email protected]",
//   domain: "mailinator.com",
//   score: 95,
//   reason: "blocklist_match",
//   mx_valid: true,
//   domain_age_days: 4380,
//   cached: false
// }

// Bulk check (up to 100 emails)
const results = await checker.checkBulk([
  '[email protected]',
  '[email protected]',
]);

The API client automatically falls back to offline detection if the API is unreachable.

How It Works

  1. Offline mode (default): Checks against a bundled blocklist of 161,000+ known disposable email domains. Instant, synchronous, zero network calls.

  2. API mode (optional): Adds real-time DNS/MX record validation, domain age checks via RDAP, and a composite risk score from 0-100. Requires an API key from isdisposable.com.

API

isDisposable(email: string): boolean

Synchronous check. Returns true if the email domain is disposable.

isDisposableBulk(emails: string[]): boolean[]

Synchronous bulk check. Returns array of booleans.

isDomainDisposable(domain: string): boolean

Check a domain directly (without an email address).

createIsDisposable(config): ApiClient

Create an API client for enhanced detection.

Config options:

| Option | Type | Default | Description | |--------|------|---------|-------------| | apiKey | string | — | Your API key from isdisposable.com | | apiUrl | string | https://isdisposable.com | API base URL | | timeout | number | 5000 | Request timeout in ms | | cache | boolean | true | Enable response caching | | cacheTTL | number | 3600 | Cache TTL in seconds |

Contributing

Found a domain that should be blocked? Open an issue or PR on the GitHub repo with the domain name. We review and update the blocklist regularly.

License

MIT


Built by Junaid Shaukat. Dashboard and API at isdisposable.com.

Part of the isDisposable ecosystem. feedback and contact here --> [email protected]