SShortSingh.
Back to feed

How to Build a Zero-Dependency Email Verification Service Using Node.js

0
·1 views

A developer tutorial published on DEV Community demonstrates how to build a basic email verification service using only Node.js and its standard library, with no third-party packages required. The service checks email syntax, flags disposable, free, and role-based addresses, and performs MX record lookups via DNS. Checks are ordered by cost, with local syntax validation running first and the single network call — the MX lookup — running last with a 1,500ms timeout. The timeout is designed to resolve as inconclusive rather than rejecting a valid address, avoiding a common flaw in homegrown verifiers that treat DNS failures as invalid addresses. The approach suits developers who need SMTP-level checking, have high verification volumes, or must keep address data within their own network.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Next.js, Supabase, and Vercel: A Practical Free-Tier Stack for Client Sites

A developer has shared the free-tier stack they use to build and ship client websites quickly, combining Next.js, Supabase, and Vercel for a streamlined workflow. Supabase provides a managed Postgres database, authentication, and storage with a generous free tier, while Vercel enables git-push deployments with preview URLs for client review. The developer highlights a commonly overlooked licensing detail: Vercel's Hobby plan is restricted to non-commercial use, requiring an upgrade to the $20/month Pro plan once a client site goes live commercially. They also note the importance of setting an uptime ping on Supabase to prevent the platform's automatic 7-day pause on inactive projects. The write-up was motivated by a gap in similar guides that fail to address how deployment terms change when a project moves from staging to a live, revenue-generating site.

0
ProgrammingDEV Community ·

MailProbe Uses 1,400-Domain List to Auto-Detect Disposable Email Signups

Disposable email addresses pose a growing problem for online platforms, quietly degrading open rates and inflating bounce complaints after free-tier signups. Manual review of suspicious addresses is inconsistent and unscalable, prompting developers to seek automated solutions. MailProbe, a self-hosted email verification tool, maintains a curated list of roughly 1,400 known disposable domains and checks each signup address against it via a fast, local dictionary lookup requiring no network call. The tool also performs syntax checks, MX record lookups, and role-address detection in a single API response, with the disposable check designed to short-circuit costlier operations when a match is found. Because the disposable-provider landscape changes frequently, the list requires regular scheduled updates — recommended weekly — to remain effective.

0
ProgrammingDEV Community ·

MX Lookup vs SMTP Verification: Why Confusing the Two Costs You Customers

MX record lookup and SMTP verification are two distinct email validation methods that are often mistakenly treated as interchangeable. An MX lookup is a DNS query that only confirms whether a domain has mail server infrastructure, but reveals nothing about whether a specific email address inbox exists. SMTP verification goes further by opening a direct connection to the mail server to check if a particular mailbox is real, but its reliability has declined significantly by 2026. Most cloud hosts block port 25, major providers distrust unrecognized IPs, and many servers return false positives to prevent account enumeration. As a result, MX lookup remains broadly accessible, while effective SMTP verification now requires a self-hosted setup with an established sending reputation and a fixed IP address.

0
ProgrammingDEV Community ·

Why Catch-All Email Domains Fool Verification Tools Into False Positives

A catch-all email domain is configured to accept messages sent to any address at that domain, regardless of whether the specific inbox exists. Standard verification methods like syntax checks and MX record lookups confirm only that the domain can receive mail, not that a particular local address is valid or monitored. Even SMTP probing fails to distinguish real from fake inboxes on catch-all domains, since the server returns a positive response to every query by design. Some verification services flag such domains as risky and reduce their scores, but this risks discarding legitimate business contacts like sales@ or info@ addresses. Experts suggest the better approach is to lower confidence scores for catch-all addresses rather than rejecting them outright, treating the issue as a confidence problem rather than a validity one.