Article

Best Node.js Email Validation Libraries in 2026 (Compared)

By Unlimited Verifier Team ·

Diagram showing a Node.js email validation flow where validator.js or Zod checks syntax at the signup form and a hosted verification API checks mailboxes in bat

Summary

The best Node.js setup for most teams combines a syntax library like validator.js or Zod at the form with a hosted API for mailbox-level checks on lists. npm packages can't reliably confirm a mailbox exists, because SMTP probes are often blocked or unanswered. Pick tools by the layer they cover, not by download count.

The best Node.js setup for most teams pairs validator.js for instant syntax checks at the form with Unlimited Verifier's REST API for batch mailbox checks, because an npm package can't reliably confirm that a mailbox exists when SMTP probes are often blocked. This guide is for developers, technical marketers and agencies building signup flows, list-cleaning jobs or sending pipelines in Node.js. It pairs well with our guide to real-time email validation.

Quick answer

Which Node.js email validation libraries are best?

For most teams, the best options are validator.js for syntax, Zod or Joi for schema validation, and a hosted API for anything that needs a mailbox check. Pick by layer, not by download count, because each tool answers a different question.

Quick picks

Tool Starting price Free tier Catch-all handling Best for
Unlimited Verifier API Web Free plan $0; API requires Pro at $29/mo ($25/mo billed annually) Free plan has no API access Detects catch-alls and routes them to Risky Mailbox checks in batch pipelines
validator.js Free (open source) n/a Not detected (syntax only) Syntax checks on input and in APIs
Zod Free (open source) n/a Not detected TypeScript schema validation
Joi Free (open source) n/a Not detected Rule-based schemas in hapi and Express
email-existence Free (open source) n/a Varies Small self-hosted mailbox probes
deep-email-validator Free (open source) n/a Varies Multi-check results in one call
mailchecker Free (open source) n/a Not applicable Disposable-domain blocking
DIY (node:dns + node:net) Your infrastructure and engineering time n/a Only via your own random-address probe Zero third-party dependencies

Bottom line: no single library covers every layer, so combine a syntax library at the form with a managed mailbox check for lists.

How we compared (and limitations)

We judged each option on the criteria that matter inside a Node.js system:

  1. Layer coverage. Does it check syntax, DNS/MX, the SMTP mailbox, catch-all domains or disposable domains?
  2. Runtime fit. Is it a built-in module or a dependency? Can a request handler await it without blocking the user?
  3. Failure modes. What does it get wrong, and in which direction: false accepts (bad addresses pass) or false rejects (good addresses fail)?
  4. Operational burden. Does it need outbound port 25, IP reputation management, caching or concurrency limits you must build yourself?
  5. Maintenance signals. Check the last release date, open issues and download trends on npm before you adopt any package.

Limitations. This comparison is based on public documentation, package READMEs and widely documented protocol behavior. We did not benchmark these libraries, run accuracy tests or measure latency. Package maintenance changes quickly, so verify each one yourself. The 99.5% accuracy figure for deep verification is Unlimited Verifier's own stated number, not an independent result. Test any accuracy claim on a sample of your own list that includes known-good and known-bad addresses.

Bottom line: treat this as a map of which layer each option covers. Verify maintenance and accuracy before you commit.

Which checks can a Node.js library actually perform?

Email validation has five layers, and most npm packages stop at the first one. Syntax checks confirm that a string matches the address grammar in RFC 5322. They don't confirm that the domain exists, accepts mail or has a real mailbox behind it.

Layer What it proves Typical Node tool
Syntax Text matches the address grammar validator.js, Zod, Joi
Domain/MX The domain has mail servers DIY node:dns, deep-email-validator
Mailbox (SMTP) A server accepted the recipient at probe time email-existence, deep-email-validator, Unlimited Verifier
Catch-all The domain accepts any local part Unlimited Verifier (routes to Risky), DIY random-address probe
Disposable/role The address is throwaway or shared mailchecker, Unlimited Verifier flags

Even the mailbox layer is probabilistic. A probe records what a server said at one moment, and a catch-all domain can accept any address. A sound pipeline routes uncertain results to Risky rather than forcing a yes or no.

Bottom line: a syntax library answers "is this well-formed?" but not "will this get delivered?", so plan a separate layer for the second question.

Can a Node.js script confirm that a mailbox exists?

Not reliably from an application server, and the reason is practical rather than theoretical. A mailbox check opens an SMTP session on port 25, sends RCPT TO for the address and reads the reply code. RFC 5321 defines 2xx replies as acceptance, 4xx as temporary failure and 5xx as permanent failure.

Three things make that signal weak:

A practical rule: classify a 2xx as a probable Valid only after a catch-all test on the same domain, treat 5xx as a probable Invalid only when it's the recipient reply rather than a policy block, and send everything else to Risky. That's the logic a managed service encodes for you, and it's why the mailbox layer is usually the one worth outsourcing. For the underlying causes of blocked probes, see why SMTP email verification gets blocked.

Bottom line: an SMTP reply is evidence about a mailbox, not proof, so build your rules around uncertainty.

The 8 best Node.js email validation libraries and services, reviewed

1. Unlimited Verifier API (best hosted option for Node pipelines)

Unlimited Verifier is a hosted bulk verification service rather than an npm package. Your Node code calls its REST API with an API key. The service checks syntax, domain, MX records and the SMTP mailbox, detects catch-all domains, flags disposable and role-based addresses, and sorts every address into Valid, Risky or Invalid. Its use case sits within email verification API and automation: your pipeline sends a list, receives buckets and decides what to do next.

Key features

Pros

Cons

Best for: Node jobs that clean large lists or check new signups in batches, without managing SMTP infrastructure.

Where it falls short: keystroke-level validation, where a remote call on every input adds latency.

Pricing: The web Free plan includes 25 lists a month of up to 150 emails each, plus 750 deep verifications a month, but no API. Pro is $29/month, or $25/month billed annually. It includes API access (100,000 emails a month), 25,000 deep verifications a month and lists of up to 25,000 emails. You can sign up and test your file format on the Free plan before you upgrade.

Tip: run validator.js first to reject malformed input, and send only well-formed addresses to the paid mailbox check. This keeps API volume for addresses that could actually be delivered.

Bottom line: the most complete option here for mailbox and catch-all decisions, provided you're on Pro and store results yourself.

2. validator.js (best for syntax and input sanitization)

validator.js is a widely used string-validation library in the JavaScript ecosystem, and several framework validators build on it. Its isEmail() function checks an address against a grammar and accepts options such as require_tld, allow_display_name, allow_utf8_local_part and allow_ip_domain.

Key features

Pros

Cons

Best for: instant feedback on signup forms and input sanitization in APIs.

Where it falls short: deciding whether a list is deliverable.

Pricing: free and open source.

Tip: trim whitespace and lowercase only the domain before validating, since RFC 5321 allows the local part to be case-sensitive. Don't reject plus-tags such as name+news@example.com, which are valid and common. For a full walkthrough, see how to validate email in JavaScript.

Bottom line: the standard syntax gate for Node, but it won't catch a typo domain or a dead mailbox.

3. Zod (best for TypeScript schemas)

Zod is a TypeScript-first schema library. Its z.string().email() check is pattern-based, so it verifies format rather than deliverability. Its real strength is composition: one schema gives you the TypeScript type, runtime validation and error messages.

Key features

Pros

Cons

Best for: TypeScript projects that want one schema for forms and server routes.

Where it falls short: any check beyond syntax, unless you write that code yourself.

Pricing: free and open source. See the Zod documentation for current usage.

Tip: keep the Zod email check synchronous for instant feedback. Put the mailbox check in an async refinement that runs only on submit, or move it out of the request entirely into a queue.

Bottom line: the best fit for TypeScript teams, provided you treat it as a format check and add deliverability separately.

4. Joi (best for rule-based backend schemas)

Joi is a mature schema library, widely used with hapi and Express. Its string().email() rule goes beyond pattern matching: the tlds option checks the suffix against the IANA list by default and can take a custom allow-list, and minDomainSegments requires a dotted domain.

Key features

Pros

Cons

Best for: hapi or Express backends that already use Joi for request validation.

Where it falls short: TypeScript-first front ends, and any deliverability decision.

Pricing: free and open source. See the Joi documentation.

Tip: require minDomainSegments of 2 and a TLD policy, then log rejections for the first week. Legitimate new TLDs are the usual false rejects, so review them before you enforce the rule strictly.

Bottom line: a solid backend schema tool with a better suffix policy than most hand-written patterns, but still short of deliverability.

5. email-existence (best self-hosted mailbox probe, with caveats)

email-existence is one of the few npm packages that attempts a mailbox check. It performs a DNS MX lookup and then an SMTP handshake that asks the server whether it would accept a given recipient. Everything runs on your infrastructure.

Key features

Pros

Cons

Best for: small internal lists from a host where you control port 25 and can accept uncertain results.

Where it falls short: large lists and any decision that needs a reliable answer.

Pricing: free and open source. Check the npm listing for current maintenance status before you adopt it.

Tip: run probes at low concurrency per domain, and treat a failed probe as Risky rather than Invalid until a second method confirms it.

Bottom line: a useful experiment on small lists, not a substitute for a managed mailbox check at scale.

6. deep-email-validator (best for multi-check results)

deep-email-validator bundles several checks into one call: format, MX, an SMTP probe and list checks such as disposable and free-provider detection. According to its documentation, it returns results per check, so you can see which layer failed.

Key features

Pros

Cons

Best for: internal tools that need per-check results without building the pipeline yourself.

Where it falls short: high-volume list cleaning, where a managed service with batch processing and a stated accuracy figure is easier to govern.

Pricing: free and open source. Confirm the license and maintenance status on npm.

Tip: log per-check output for every rejected address during the first two weeks. You'll see which failure mode dominates your list before you enforce any rule.

Bottom line: a convenient bundle for internal use, but it carries the same mailbox-probe limits as any SMTP-based tool.

7. mailchecker (best for disposable-domain blocking)

mailchecker matches an address's domain against a list of known disposable and throwaway email providers. It's built to stop free-trial abuse and throwaway signups, not to verify that a mailbox exists.

Key features

Pros

Cons

Best for: blocking disposable signups on free trials and gated downloads.

Where it falls short: deciding whether an address is deliverable.

Pricing: free and open source.

Tip: on a paid checkout, don't hard-block every disposable domain. Ask for extra confirmation instead, because some legitimate customers use temporary addresses for privacy. For wider signup hygiene, see how to add real-time email verification to signup forms.

Bottom line: a narrow, useful filter that works best alongside a confirmation step.

8. DIY with node:dns and node:net (best zero-dependency option)

You can build a basic pipeline from Node's built-in modules. dns.promises.resolveMx looks up mail servers, url.domainToASCII converts internationalized domains to ASCII, and node:net opens the SMTP socket. This gives you full control over timeouts and concurrency, with no third-party code. For the DNS part in depth, see how to check MX records programmatically.

Key features

Pros

Cons

Best for: teams that want an auditable DNS check and have the engineering time to maintain a mailbox probe.

Where it falls short: mailbox-level accuracy at scale.

Pricing: your own infrastructure and engineering time.

Tip: detect catch-alls with a random-address probe. Send a probe to a nonexistent local part on the same domain. If the server accepts it, the domain probably accepts any address, so route its addresses to Risky.

Bottom line: the cleanest option for a DNS check, but a mailbox check you build yourself carries the same limits as any SMTP probe.

How do you validate emails in a Node.js pipeline?

The most reliable approach has two stages: a fast syntax check at input, and a batch mailbox check on the stored list. The steps below use Unlimited Verifier as the mailbox layer. Adjust the placeholders to match the API documentation.

  1. Add a syntax gate. Install validator.js with npm install validator, then validate every address at the form or API boundary. Trim whitespace before you check.
const validator = require('validator');

function normalize(raw) {
  const trimmed = raw.trim();
  const at = trimmed.lastIndexOf('@');
  if (at < 1) return trimmed;
  // Lowercase the domain only. RFC 5321 allows the local part to be case-sensitive.
  return trimmed.slice(0, at) + '@' + trimmed.slice(at + 1).toLowerCase();
}

function isWellFormed(raw) {
  return validator.isEmail(normalize(raw), { require_tld: true });
}
  1. Handle internationalized domains. Convert them with Node's built-in URL module before any DNS lookup. url.domainToASCII('español.com') returns xn--espaol-zwa.com. See the Node.js DNS documentation for the lookup side.

  2. Create an account. Sign up and test your CSV on the Free plan. The API requires Pro, so upgrade before you wire up the job.

  3. Create an API key. Generate one on the Email verification API page and store it in an environment variable, never in source control.

  4. Batch the list. Split addresses into groups of up to 10,000 per request. A 50,000-address list needs 50,000 ÷ 10,000 = 5 requests.

function chunk(items, size = 10000) {
  const out = [];
  for (let i = 0; i < items.length; i += size) out.push(items.slice(i, i + size));
  return out;
}
  1. Call the API. Use Node's built-in fetch, available in Node 18 and later. Replace the placeholders with the endpoint, auth header and body format from the API documentation. Run batches sequentially, or with a small parallel limit. For throttling strategy, see email validation API rate limits explained.
// Placeholders: take the endpoint, auth header and body shape from the API docs.
async function verifyBatch(emails) {
  const res = await fetch(process.env.VERIFY_URL, {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' /* plus your auth header */ },
    body: JSON.stringify({ emails }), // adjust to the documented body format
  });
  if (!res.ok) throw new Error(`Verification failed: ${res.status}`);
  return res.json();
}
  1. Store results immediately. Write each address, its bucket (Valid, Risky or Invalid) and a timestamp to your own database. Pro results are kept on the platform for 30 days only.

  2. Apply your rules. Send to Valid addresses. Suppress Invalid addresses. Segment Risky addresses (catch-alls, disposables and role-based addresses) by engagement. For the policy details, see email list maintenance best practices. These rules are part of wider email verification compliance and hygiene.

  3. Spot-check without code. For one-off checks, use the free email checker. For a no-code bulk run, upload a CSV instead of calling the API.

  4. Schedule it. Run the batch job weekly on new signups and quarterly on the full list.

Worked example (illustrative list size). Assume a 50,000-address list plus about 700 new signups a week.

Bottom line: keep validator.js at the edge, run batch mailbox checks on a schedule, and store every result on your side.

Which Node.js email validation option should you choose?

Match the option to your bottleneck: input quality, deliverability decisions, disposable abuse or zero dependencies. The table below is a starting point.

Your situation Pick Why
Signup form needs instant feedback validator.js or Zod Syntax check with no network call
TypeScript front end and back end Zod One schema for both
Express or hapi backend with Joi Joi Mature rules and suffix policy
Clean a 50,000-address list from a Node job Unlimited Verifier API (Pro) Batch mailbox checks with Valid/Risky/Invalid buckets
Block throwaway trial signups mailchecker Fast disposable-domain match
Small internal list, port 25 open email-existence or deep-email-validator Free probe with caveats
Zero third-party dependencies DIY node:dns + node:net Full control, full maintenance

For a wider market view, see our roundup of the best email verification tools. For bulk sales lists, see email verification for sales prospecting. For SaaS and ecommerce sign-up flows, see email verification for ecommerce and SaaS. If your backend is Python rather than Node, see best Python libraries for email validation.

Bottom line: use a syntax library at the form and a managed batch check for the list, and build a probe yourself only if you can maintain it.

What mistakes do Node developers make with email validation?

Bottom line: most Node.js validation failures come from treating a single check as the final answer, not from the library.

Verdict

For Node.js teams, the best answer is a two-layer setup: validator.js (or Zod) at the form for instant syntax checks, and a hosted mailbox-verification API for lists and uncertain addresses. An npm package can't reliably confirm a mailbox on its own, so the mailbox layer is where most deliverability decisions get made.

Unlimited Verifier's API is the strongest hosted option in this list for batch pipelines. It returns Valid, Risky and Invalid buckets with catch-all detection, accepts up to 10,000 emails per request and offers unlimited standard verification on every plan. The API requires Pro, which is $25/month billed annually, so store results in your own database.

Bottom line: start with validator.js today, add batch mailbox checks through the API once you're on Pro, and keep your sending list clean on a weekly and quarterly schedule.

Layered validation flow

  1. Form (instant): validator.js or Zod checks syntax and rejects malformed input.
  2. Disposable filter: mailchecker blocks known throwaway domains.
  3. Batch or uncertain addresses: send to a hosted verification API for mailbox-level status.
  4. Route results: Valid = send; Risky (catch-all) = send with caution or re-engage; Invalid = suppress.
  5. Re-verify lists on a schedule so stale addresses don't hurt deliverability.

Frequently asked questions

What is the best Node.js library for email validation?

validator.js is the most common choice for syntax checks, and Zod suits TypeScript schemas. Neither confirms a mailbox exists. For that, most teams add a hosted verification API for batch lists and uncertain addresses, since npm packages can't reliably probe SMTP.

Can a Node.js library confirm an email mailbox exists?

Not reliably. Many networks block outbound port 25, and many mail providers don't answer recipient probes. Self-hosted SMTP checks can return misleading results, so treat an 'exists' response as a signal, not proof.

What is a catch-all email address?

A catch-all domain accepts mail for any address on it, so an SMTP check always appears to succeed even when the specific mailbox is fake. Good verifiers flag these as risky rather than valid.

Is validator.js enough for form validation?

For most signup forms, yes at the syntax layer. It catches malformed addresses instantly. It won't detect typos in real domains, disposable addresses, or nonexistent mailboxes, so add a disposable-domain check or a verification step if those matter.

How do I block disposable email addresses in Node.js?

Use mailchecker, which matches known throwaway domains against a maintained list. It's fast and free, but it only detects known disposable providers and doesn't confirm that a mailbox exists.

Should I use Zod or Joi for email validation?

Choose Zod if your project is TypeScript-first and you want inferred types from schemas. Choose Joi if you run hapi or Express and prefer a rule-heavy, declarative API. Both are free and open source, and both need a separate tool for mailbox checks.

Can I validate emails in bulk with Node.js?

Yes. Send lists through a hosted API in batches, then handle results by status: send to valid, review risky catch-alls, and suppress invalid. Batch endpoints avoid the rate-limit and port-blocking problems of running SMTP probes yourself.

Is a DIY email check with node:dns and node:net worth building?

It works for syntax, MX lookup, and simple probes with zero third-party dependencies. However, you must handle port blocking, timeouts, greylisting, and catch-alls yourself, so expect ongoing maintenance and engineering time.

Cut Bounces and Protect Your Sender Reputation With Unlimited Email Verification

Every invalid address you send to hurts your sender reputation and your inbox placement. Verifying your list before each send means fewer bounces, healthier deliverability, and a predictable cost. With Unlimited Verifier, standard verification is unlimited on every plan, with no per-email fees.

Unlimited Verifier checks syntax, domain, MX records and the SMTP mailbox. It also detects catch-all domains and flags disposable and role-based addresses. Export a CSV from your email platform or CRM, upload and verify the list, then re-import the clean results. You can also automate checks with the email verification API.

Free Pro
Price $0 $29/month ($25/month billed annually)
Lists 25 a month, up to 150 emails each Unlimited, up to 25,000 emails each
Deep verifications 750 a month 25,000 a month
API access No Yes (100,000 emails a month)
Result retention 24 hours 30 days

Why teams choose Unlimited Verifier

Unlimited Verifier states 99.5% accuracy for deep verification.

Create a free account and verify your next list before you hit send.

Want to test a single address first? Try the free email checker.