single email verifier

 <!DOCTYPE html>

<html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Single Email Verifier</title> <meta name="description" content="Quick single email verification tool with advanced validation - no API required."> <link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>✉️</text></svg>"> <script src="https://cdn.tailwindcss.com"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css" /> <style> :root { --primary: #3b82f6; --primary-dark: #2563eb; --success: #10b981; --warning: #f59e0b; --danger: #ef4444; --gray: #6b7280; --light-gray: #f3f4f6; } body { background: #000000; min-height: 100vh; font-family: Georgia, 'Times New Roman', Times, serif; font-weight: 300; color: #c084fc; transition: all 0.3s ease; overflow-x: hidden; padding: 1rem; } body.dark-mode { background: #000000; color: #c084fc; } body::before { content: ''; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at 20% 80%, rgba(192, 132, 252, 0.05) 0%, transparent 50%), radial-gradient(circle at 80% 20%, rgba(147, 51, 234, 0.05) 0%, transparent 50%), radial-gradient(circle at 40% 40%, rgba(168, 85, 247, 0.05) 0%, transparent 50%); pointer-events: none; z-index: -1; } .glass-card { background: rgba(30, 30, 30, 0.8); backdrop-filter: blur(30px); border: 1px solid rgba(192, 132, 252, 0.2); box-shadow: 0 25px 45px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(192, 132, 252, 0.1); transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); position: relative; overflow: hidden; } .glass-card::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(192, 132, 252, 0.1), transparent); transition: left 0.8s ease; } .glass-card:hover::before { left: 100%; } .glass-card:hover { transform: translateY(-2px); box-shadow: 0 35px 60px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(192, 132, 252, 0.2); border-color: rgba(192, 132, 252, 0.3); } .input-area { background: rgba(40, 40, 40, 0.8); border: 2px solid rgba(192, 132, 252, 0.3); transition: all 0.3s ease; backdrop-filter: blur(10px); color: #c084fc; } .input-area:focus { background: rgba(50, 50, 50, 0.9); border-color: rgba(192, 132, 252, 0.6); box-shadow: 0 0 0 4px rgba(192, 132, 252, 0.1); } .btn-primary { background: linear-gradient(135deg, #8b5cf6 0%, #a855f7 50%, #c084fc 100%); background-size: 200% 200%; border: none; transition: all 0.4s ease; position: relative; overflow: hidden; box-shadow: 0 8px 25px rgba(192, 132, 252, 0.4); color: #000000; } .btn-primary:before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transition: left 0.6s; } .btn-primary:hover { background-position: 100% 0%; transform: translateY(-1px) scale(1.02); box-shadow: 0 12px 30px rgba(192, 132, 252, 0.6), 0 0 20px rgba(168, 85, 247, 0.4); } .btn-primary:hover:before { left: 100%; } .btn-primary:active { transform: translateY(0px) scale(0.98); } .result-card { background: rgba(40, 40, 40, 0.8); border-left: 4px solid rgba(192, 132, 252, 0.5); transition: all 0.3s ease; animation: slideIn 0.5s ease-out; color: #c084fc; } .result-card.valid { border-left-color: #10b981; background: rgba(16, 185, 129, 0.1); } .result-card.invalid { border-left-color: #ef4444; background: rgba(239, 68, 68, 0.1); } .result-card.warning { border-left-color: #f59e0b; background: rgba(245, 158, 11, 0.1); } @keyframes slideIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } } .loading-spinner { border: 2px solid #f3f3f3; border-top: 2px solid var(--primary); border-radius: 50%; width: 16px; height: 16px; animation: spin 1s linear infinite; } @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } } .status-badge { padding: 0.25rem 0.75rem; border-radius: 15px; font-size: 0.75rem; display: inline-flex; align-items: center; gap: 0.5rem; position: relative; } .status-badge.valid { background: rgba(16, 185, 129, 0.2); color: #10b981; } .status-badge.invalid { background: rgba(239, 68, 68, 0.2); color: #ef4444; } .status-badge.warning { background: rgba(245, 158, 11, 0.2); color: #f59e0b; } .theme-toggle { position: fixed; bottom: 1rem; right: 1rem; background: rgba(40, 40, 40, 0.8); backdrop-filter: blur(10px); border: 1px solid rgba(192, 132, 252, 0.3); border-radius: 50%; width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; color: #c084fc; transition: all 0.3s ease; cursor: pointer; z-index: 1000; } .theme-toggle:hover { background: rgba(60, 60, 60, 0.9); border-color: rgba(192, 132, 252, 0.5); transform: scale(1.05); } @media (max-width: 640px) { body { padding: 0.5rem; } .glass-card { margin: 0.5rem; } } </style> </head> <body> <div class="max-w-md mx-auto"> <!-- Header --> <div class="text-center mb-4"> <h1 class="text-lg md:text-xl font-light text-white mb-2 drop-shadow-2xl bg-gradient-to-r from-purple-300 via-purple-400 to-purple-500 bg-clip-text text-transparent" style="font-family: Georgia, serif; font-weight: 300; letter-spacing: 0.02em;"> Email Verifier </h1> <p class="text-xs font-light" style="font-family: Georgia, serif; font-weight: 300; color: #a78bfa;">Quick single email validation</p> </div> <!-- Main Verifier --> <div class="glass-card rounded-xl p-4 mb-4"> <div class="mb-3"> <label class="block text-xs font-light mb-1" style="font-family: Georgia, serif; font-weight: 300; color: #c084fc;"> Enter Email Address </label> <input type="email" id="emailInput" class="input-area w-full p-2 rounded-lg focus:outline-none text-xs" placeholder="example@domain.com" style="font-family: Georgia, serif; font-weight: 300;" /> </div> <button id="verifyBtn" class="btn-primary w-full py-2 rounded-lg font-light text-black flex items-center justify-center gap-1 text-xs mb-3" style="font-family: Georgia, serif; font-weight: 300;"> <i class="fas fa-check-circle text-xs"></i> <span id="btnText">Verify Email</span> </button> <!-- Result Container --> <div id="resultContainer" class="hidden"> <div id="resultCard" class="result-card p-3 rounded-lg border-l-4"> <div class="flex items-center justify-between mb-2"> <div class="flex-1"> <div class="font-light text-xs mb-1" id="emailDisplay" style="font-family: Georgia, serif; color: #c084fc;"></div> <div id="statusBadge" class="status-badge text-xs"> <i id="statusIcon"></i> <span id="statusText"></span> </div> </div> </div> <div class="mt-2 space-y-1"> <div id="scoreDisplay" class="text-xs" style="color: #a78bfa;"></div> <div id="issuesDisplay" class="text-xs text-red-400 hidden"></div> <div id="warningsDisplay" class="text-xs text-yellow-400 hidden"></div> </div> <div class="mt-2 grid grid-cols-2 gap-2 text-xs" style="color: #a78bfa;"> <div>Format: <span id="formatCheck"></span></div> <div>Domain: <span id="domainCheck"></span></div> <div>Reputation: <span id="reputationScore"></span>/100</div> <div>Type: <span id="emailType"></span></div> </div> </div> </div> </div> </div> <!-- Theme Toggle --> <div class="theme-toggle" onclick="toggleTheme()"> <i class="fas fa-moon text-sm"></i> </div> <script> // Comprehensive disposable email domains database const DISPOSABLE_DOMAINS = new Set([ '10minutemail.com', 'tempmail.org', 'guerrillamail.com', 'mailinator.com', 'yopmail.com', 'temp-mail.org', 'disposablemail.com', 'throwawaymail.com', 'spam4.me', 'fakeinbox.com', 'tempinbox.com', 'trashmail.com', 'mailnesia.com', 'getnada.com', 'sharklasers.com', 'burnermail.io', 'tempmail.net', '10minutemail.net', 'maildrop.cc', 'getairmail.com', // Add more as needed... ]); // Email provider reputation scores const PROVIDER_REPUTATION = { 'gmail.com': 95, 'outlook.com': 95, 'hotmail.com': 90, 'yahoo.com': 90, 'apple.com': 95, 'icloud.com': 95, 'protonmail.com': 95, 'proton.me': 95, 'company.com': 85, 'organization.org': 85, 'business.co': 85, 'gmx.com': 80, 'web.de': 80, 'mail.ru': 75, 'yandex.com': 75, 'aol.com': 70, 'comcast.net': 70, 'verizon.net': 70, }; // TLD reputation const TLD_REPUTATION = { 'com': 95, 'org': 90, 'edu': 95, 'gov': 98, 'net': 85, 'co': 80, 'io': 85, 'me': 75, 'tk': 30, 'ml': 30, 'ga': 30, 'cf': 30 }; // DOM elements const emailInput = document.getElementById('emailInput'); const verifyBtn = document.getElementById('verifyBtn'); const btnText = document.getElementById('btnText'); const resultContainer = document.getElementById('resultContainer'); const resultCard = document.getElementById('resultCard'); const emailDisplay = document.getElementById('emailDisplay'); const statusBadge = document.getElementById('statusBadge'); const statusIcon = document.getElementById('statusIcon'); const statusText = document.getElementById('statusText'); const scoreDisplay = document.getElementById('scoreDisplay'); const issuesDisplay = document.getElementById('issuesDisplay'); const warningsDisplay = document.getElementById('warningsDisplay'); const formatCheck = document.getElementById('formatCheck'); const domainCheck = document.getElementById('domainCheck'); const reputationScore = document.getElementById('reputationScore'); const emailType = document.getElementById('emailType'); // Advanced email validation class class EmailValidator { constructor() { this.patterns = { rfc5322: /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/, suspicious: [ /test\d*@/i, /admin@/i, /noreply@/i, /no-reply@/i, /postmaster@/i, /mailer-daemon@/i, /abuse@/i, /\d{10,}@/, /[a-z]{20,}@/i, /(.)\1{4,}@/, /\+.*\+.*@/, /@.*\d+\.tk$/i, /@.*\d+\.ml$/i, ], business: [ /@[a-zA-Z0-9-]+\.(com|org|net|co|biz|info)$/, /^[a-zA-Z]+\.[a-zA-Z]+@/, /^[a-zA-Z]+@[a-zA-Z0-9-]+\./, ] }; } validate(email) { const result = { email: email.toLowerCase().trim(), isValid: false, score: 0, issues: [], warnings: [], details: { format: false, domain: false, tld: false, reputation: 0, isDisposable: false, isSuspicious: false, isBusiness: false } }; if (this.validateFormat(email, result)) { this.analyzeDomain(email, result); this.checkReputation(email, result); this.detectPatterns(email, result); this.calculateScore(result); } return result; } validateFormat(email, result) { if (email.length > 254) { result.issues.push('Email too long (max 254 characters)'); return false; } if (email.length < 5) { result.issues.push('Email too short'); return false; } if (!email.includes('@')) { result.issues.push('Missing @ symbol'); return false; } const parts = email.split('@'); if (parts.length !== 2) { result.issues.push('Invalid @ symbol usage'); return false; } const [localPart, domain] = parts; if (localPart.length === 0 || localPart.length > 64) { result.issues.push('Invalid local part length'); return false; } if (localPart.startsWith('.') || localPart.endsWith('.')) { result.issues.push('Local part cannot start/end with dot'); return false; } if (localPart.includes('..')) { result.issues.push('Consecutive dots not allowed'); return false; } if (domain.length === 0 || domain.length > 253) { result.issues.push('Invalid domain length'); return false; } if (!domain.includes('.')) { result.issues.push('Domain must contain at least one dot'); return false; } if (!this.patterns.rfc5322.test(email)) { result.issues.push('Does not match RFC 5322 format'); return false; } result.details.format = true; result.score += 20; return true; } analyzeDomain(email, result) { const domain = email.split('@')[1].toLowerCase(); const parts = domain.split('.'); if (parts.length < 2) { result.issues.push('Invalid domain structure'); return; } const tld = parts[parts.length - 1]; if (tld.length < 2) { result.issues.push('Invalid TLD'); return; } if (/^\d+\.\d+\.\d+\.\d+$/.test(domain)) { result.warnings.push('IP address domain detected'); result.score -= 10; } if (domain.length > 100) { result.warnings.push('Unusually long domain'); result.score -= 5; } if (parts.length > 3) { result.warnings.push('Multiple subdomains detected'); result.score -= 2; } result.details.domain = true; result.details.tld = tld; result.score += 15; } checkReputation(email, result) { const domain = email.split('@')[1].toLowerCase(); const tld = domain.split('.').pop(); if (DISPOSABLE_DOMAINS.has(domain)) { result.details.isDisposable = true; result.issues.push('Disposable email provider'); result.score -= 50; return; } let providerScore = 50; for (const [provider, score] of Object.entries(PROVIDER_REPUTATION)) { if (domain.includes(provider.toLowerCase())) { providerScore = score; break; } } const tldScore = TLD_REPUTATION[tld] || 50; result.details.reputation = Math.round((providerScore + tldScore) / 2); result.score += Math.round(result.details.reputation * 0.3); } detectPatterns(email, result) { const localPart = email.split('@')[0].toLowerCase(); const domain = email.split('@')[1].toLowerCase(); for (const pattern of this.patterns.suspicious) { if (pattern.test(email)) { result.details.isSuspicious = true; result.warnings.push('Suspicious pattern detected'); result.score -= 15; break; } } for (const pattern of this.patterns.business) { if (pattern.test(email)) { result.details.isBusiness = true; result.score += 10; break; } } if (localPart.length < 3) { result.warnings.push('Very short local part'); result.score -= 5; } if (/^\d+$/.test(localPart)) { result.warnings.push('Numeric-only local part'); result.score -= 10; } } calculateScore(result) { result.score = Math.max(0, Math.min(100, result.score)); if (result.issues.length === 0 && result.score >= 60) { result.isValid = true; } else if (result.issues.length === 0 && result.score >= 40) { result.isValid = true; result.warnings.push('Low confidence score'); } } } // Initialize validator const validator = new EmailValidator(); // Event listeners emailInput.addEventListener('keypress', (e) => { if (e.key === 'Enter') { verifyEmail(); } }); emailInput.addEventListener('input', () => { if (emailInput.value.trim()) { verifyBtn.disabled = false; } else { verifyBtn.disabled = true; resultContainer.classList.add('hidden'); } }); verifyBtn.addEventListener('click', verifyEmail); async function verifyEmail() { const email = emailInput.value.trim(); if (!email) { showNotification('Please enter an email address', 'error'); return; } // Show loading state verifyBtn.disabled = true; btnText.innerHTML = '<div class="loading-spinner mr-1"></div>Checking...'; // Simulate processing delay for better UX await new Promise(resolve => setTimeout(resolve, 500)); const result = validator.validate(email); displayResult(result); // Reset button verifyBtn.disabled = false; btnText.textContent = 'Verify Email'; } function displayResult(result) { emailDisplay.textContent = result.email; // Update status badge const statusClass = result.isValid ? 'valid' : (result.details.isDisposable || result.details.isSuspicious ? 'invalid' : 'warning'); const statusIconClass = result.isValid ? 'fa-check-circle' : (result.details.isDisposable || result.details.isSuspicious ? 'fa-times-circle' : 'fa-exclamation-triangle'); const statusTextContent = result.isValid ? 'Valid' : (result.details.isDisposable ? 'Disposable' : (result.details.isSuspicious ? 'Suspicious' : 'Warning')); statusBadge.className = `status-badge ${statusClass} text-xs`; statusIcon.className = `fas ${statusIconClass}`; statusText.textContent = statusTextContent; // Update result card class resultCard.className = `result-card ${statusClass} p-3 rounded-lg border-l-4`; // Update score scoreDisplay.textContent = `Validation Score: ${result.score}/100`; // Update issues if (result.issues.length > 0) { issuesDisplay.textContent = `Issues: ${result.issues.join(', ')}`; issuesDisplay.classList.remove('hidden'); } else { issuesDisplay.classList.add('hidden'); } // Update warnings if (result.warnings.length > 0) { warningsDisplay.textContent = `Warnings: ${result.warnings.join(', ')}`; warningsDisplay.classList.remove('hidden'); } else { warningsDisplay.classList.add('hidden'); } // Update details formatCheck.textContent = result.details.format ? '✓' : '✗'; domainCheck.textContent = result.details.domain ? '✓' : '✗'; reputationScore.textContent = result.details.reputation; if (result.details.isDisposable) { emailType.textContent = 'Disposable'; } else if (result.details.isBusiness) { emailType.textContent = 'Business'; } else if (result.details.isSuspicious) { emailType.textContent = 'Suspicious'; } else { emailType.textContent = 'Personal'; } resultContainer.classList.remove('hidden'); } function showNotification(message, type = 'info') { // Simple notification system const notification = document.createElement('div'); notification.className = `fixed top-4 right-4 p-3 rounded-lg shadow-lg z-50 text-xs ${ type === 'success' ? 'bg-green-600 text-white' : type === 'error' ? 'bg-red-600 text-white' : type === 'warning' ? 'bg-yellow-600 text-white' : 'bg-blue-600 text-white' }`; notification.style.fontFamily = 'Georgia, serif'; notification.style.fontWeight = '300'; notification.textContent = message; document.body.appendChild(notification); setTimeout(() => { notification.style.opacity = '0'; notification.style.transform = 'translateX(100%)'; setTimeout(() => { if (notification.parentNode) { notification.parentNode.removeChild(notification); } }, 300); }, 3000); } function toggleTheme() { // Theme toggle functionality (placeholder) showNotification('Theme toggle clicked', 'info'); } // Initialize verifyBtn.disabled = true; console.log('Single Email Verifier initialized successfully!'); </script> </body> </html>

Comments

Popular posts from this blog

Email Extractor

Email Separator