Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

email-seems-valid

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

email-seems-valid

An offline check to see if an email seems valid

  • 0.0.12
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
32
decreased by-40.74%
Maintainers
1
Weekly downloads
 
Created
Source

email-seems-valid
An offline check to see if an email seems valid.
Contains TS or JS packages for browser or Node.js

emailSeemsValid('test@gmail.com'); // true

emailSeemsValid('i̇test@gmail.com'); // false
emailSeemsValid('test@gmail.ocm'); // false
emailSeemsValid('test@protonmail.co'); // false


Why is this needed?

Tools like Amazon SES are picky about email addresses. It's very technical, but this library is a good offline validator that an address will work for Amazon SES and all other email senders

Usage

import { emailSeemsValid } from 'email-seems-valid';

// simple valid email addresses
emailSeemsValid('test@gmail.com');
emailSeemsValid('test@protonmail.com');
// all true

// special characters
emailSeemsValid('!test@gmail.com');
emailSeemsValid('!test@gmail.com');
emailSeemsValid('ñtest@gmail.com');
emailSeemsValid('i̇test@gmail.com');
// all false (Amazon SES rejects exclamation points)

// common mis-spellings
emailSeemsValid('test@gmail.ocm');
emailSeemsValid('test@gamail.com');
emailSeemsValid('test@protonmail.co');
// all false

This library does not provide accurate true/false all emails, but it works for 99.95%.


Trusted By

• Earnifi

Want to be added to this list? Submit a pull-request today!


More Details

Amazon SES does not support the SMTPUTF8 extension, as described in RFC6531. For this reason, the local part of a destination email address (the part of the email address that precedes the @ sign) may only contain 7-bit ASCII characters. If the domain part of an address (the part after the @ sign) contains non-ASCII characters, they must be encoded using Punycode, as described in RFC3492.

Read more here

FAQs

Package last updated on 06 Oct 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc