Node.js email verification

Verify emails in Node.js with Verifly

Node ships fetch out of the box, so adding email verification is a single async call. Verifly is an API-first, pay-as-you-go service that returns a clean JSON verdict you can await in any Express route, serverless function, or worker.

Verify one email in Node.jsAPI
const url = new URL('https://verifly.email/api/v1/verify')
url.searchParams.set('email', 'user@example.com')

const res = await fetch(url, {
  headers: { Authorization: 'Bearer vf_YOUR_KEY' },
})
const data = await res.json()
console.log(data.result, data.is_valid)

Real-time SMTP mailbox checks

Single, batch, and async bulk verification

Disposable, role account, and catch-all detection

Pay-as-you-go credits with no subscription lock-in

Search fit

Built for Node.js email verification

Use Verifly when you need a simple API, predictable pricing, and clean JSON results before emails hit your product, CRM, or campaign tool.

Validate emails in an Express or Fastify signup route
Check addresses inside a Next.js API route or server action
Clean a lead array in a serverless function on Vercel or Lambda
Filter a queue job so it only mails deliverable addresses

Email verification on modern Node.js

Since Node 18, the global fetch API is built in, which means you no longer need axios or node-fetch just to call an HTTP service. That makes Verifly especially convenient in Node: verifying an address is one await away, with no dependency to install and no SDK to keep in sync. Whether you are running an Express server, a Fastify API, a Next.js route handler, or a serverless function on Vercel or AWS Lambda, the same handful of lines works everywhere.

The problem Verifly solves is one every Node backend hits eventually. A signup form, a waitlist, or an imported CSV feeds you addresses, and validator libraries such as validator.js only check that the string looks like an email. They cannot tell you that the mailbox was deleted, that the domain is a disposable throwaway, or that the address is a generic role@ inbox nobody reads. Verifly performs a live SMTP probe and returns a JSON body with a result of deliverable, undeliverable, or risky plus disposable, role, catch-all, and smtp flags — exactly the shape you want to destructure and branch on.

Because pricing is pay-as-you-go from $2 per 1,000 checks down to $0.60 per 1,000 at volume, it scales from a hobby project to production without a plan change. Self-register for 100 free credits — no card, no captcha — and the same vf_ key works from local dev, a container, or an edge function.

Batch-verify an array of emails in Node.js

For anything beyond a single address, post the whole set to /verify/batch instead of firing dozens of requests. Send a JSON body with an emails array and get back a results array you can filter with the array methods you already use. This keeps latency low and cost predictable, which matters inside a serverless function with an execution-time budget.

Batch verification with fetch
const emails = [
  'ada@example.com',
  'info@some-domain.com',
  'noreply@disposable.tld',
]

const res = await fetch('https://verifly.email/api/v1/verify/batch', {
  method: 'POST',
  headers: {
    Authorization: 'Bearer vf_YOUR_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({ emails }),
})

const { results } = await res.json()
const clean = results.filter((r) => r.result === 'deliverable')
console.log(`Keeping ${clean.length} of ${results.length}`)
for (const r of results) {
  if (r.disposable || r.role) console.log('drop:', r.email, r.result)
}

Guard an Express or Next.js signup route

The best place to verify in a Node app is the endpoint that creates an account. A short-timeout fetch, wrapped so a network error fails open rather than blocking the user, lets you reject disposable addresses and warn on undeliverable ones before you write the row. Use an AbortController to cap the wait so verification never becomes a bottleneck on your signup path.

Reject bad emails in a signup handler
async function isEmailOk(email) {
  const ctrl = new AbortController()
  const t = setTimeout(() => ctrl.abort(), 8000)
  try {
    const url = new URL('https://verifly.email/api/v1/verify')
    url.searchParams.set('email', email)
    const res = await fetch(url, {
      headers: { Authorization: 'Bearer vf_YOUR_KEY' },
      signal: ctrl.signal,
    })
    const data = await res.json()
    if (data.disposable) return false
    return data.result !== 'undeliverable'
  } catch {
    return true // fail open on network error
  } finally {
    clearTimeout(t)
  }
}

FAQ

Frequently asked questions

Do I need axios or node-fetch to use Verifly?

No. Node 18 and later ship a global fetch, so you can call Verifly with zero dependencies. axios, node-fetch, or undici work too if you already use them, but they are not required.

Can I call Verifly from a Next.js API route or server action?

Yes. Verifly is a plain REST endpoint, so it works from any server-side context — route handlers, server actions, getServerSideProps, or middleware. Keep the vf_ key server-side and never expose it to the browser.

How should I verify many emails in a serverless function?

Use POST /api/v1/verify/batch with an emails array rather than looping the single endpoint. One request returns all results, which keeps you well inside a serverless execution-time limit and costs less.

What is in the JSON response?

Each result has result (deliverable, undeliverable, or risky), is_valid, and boolean flags disposable, role, catch_all, and smtp. Destructure it and branch on result, then use the flags to strip throwaway or role addresses.

How do I stop verification from slowing down signup?

Wrap the fetch in an AbortController with a timeout of a few seconds and fail open on error. That caps the added latency and guarantees a transient network problem never blocks a real registration.

What does Node.js email verification cost?

It is pay-as-you-go from $2 per 1,000 checks down to $0.60 per 1,000 at volume, with 100 free credits on self-register. No subscription, so small projects only pay for the checks they run.