Official Library

PHP Email Verification SDK

The official PHP client for EmailVerify.io, providing stable, high-performance email validation and lead discovery tools for Laravel, Symfony, and modern PHP applications.

Free plan available. No credit card required.

sdk-example.worker

Composer Setup

Install the EmailVerify PHP SDK using Composer.

terminal
$ composer require emailverifyio/emailverify

Implementation Guide

1 Standard Verification

Official PHP client for real-time SMTP verification. Fully OOP-compatible and easy to integrate into any PHP 7.4+ application.

php
use EmailVerify\Client;

$client = new Client('your_api_key');
$result = $client->verify('[email protected]');

if ($result->isValid()) {
    echo "This email is deliverable!";
}

2 High-Throughput Batching

Process large email lists efficiently. Our batch API handles millions of records with high concurrency and automatic status polling.

php
$emails =['[email protected]', '[email protected]'];
$batch = $client->batch->create($emails);

// Polling for results
$status = $client->batch->status($batch->id);
if ($status->isCompleted()) {
    $results = $client->batch->results($batch->id);
    var_dump($results->summary);
}

3 Client Configuration

Advanced configuration options for enterprise environments. Customize timeouts, proxies, and custom headers for your HTTP client.

php
$client = new Client('key',[
    'timeout' => 10.0,
    'verify_ssl' => true,
    'proxy' => 'tcp://localhost:8125',
    'headers' =>['X-App-Name' => 'MarketingPlatform']
]);

4 Email Finder API

Identify professional email addresses using name and domain heuristics. High confidence results for your outreach and sales lead generation.

php
$lead = $client->finder->search([
    'first_name' => 'John',
    'last_name' => 'Wick',
    'domain' => 'continental.com'
]);

if ($lead->email) {
    echo "Found: " . $lead->email . " (Conf: " . $lead->confidence . "%)";
}

5 Syntax Correction

Improve user data quality at the point of entry. Detect syntax errors and provide instant suggestions for common domain typos.

php
$check = $client->syntax->validate('[email protected]');
if (!$check->valid && $check->suggestion) {
    echo "Did you mean " . $check->suggestion . "?";
}

6 Framework Integration

Seamlessly integrate with Laravel, Symfony, or any PSR-compatible framework. Works perfectly with Dependency Injection and Service Providers.

php
// In a Controller or Service
public function register(Request $request) {
    $v = resolve(EmailVerify\Client::class)->verify($request->email);
    if ($v->isDisposable()) {
        return back()->withError('Disposable emails not allowed.');
    }
}

7 Robust Error Handling

Build resilient integrations with specific exception handling. Catch rate limits, authentication errors, and network failures gracefully.

php
try {
    $res = $client->verify($email);
} catch (\EmailVerify\Exceptions\RateLimitException $e) {
    // Handle 429 Too Many Requests
} catch (\EmailVerify\Exceptions\ApiException $e) {
    // Handle general API issues
}

8 Security & Risk Filters

Protect your domain reputation by filtering out risky emails. Detect disposable providers and spam traps before you send.

php
$res = $client->verify('[email protected]');
if ($res->isDisposable()) {
    Log::warning("Disposable email attempt: " . $res->email);
}
if ($res->isSpamTrap()) {
    echo "Warning: High risk email detected.";
}
FAQs

Frequently Asked Questions

Question Icon

How do I install the PHP SDK?

We recommend using Composer for installation. Simply run `composer require emailverifyio/emailverify` to add it to your project.

Question Icon

Is it compatible with Laravel and Symfony?

Yes, the SDK is a pure PHP library and works perfectly with any modern PHP framework.

Question Icon

What PHP version is required?

The SDK is compatible with PHP 7.4 and higher, including the latest PHP 8.x versions.

Question Icon

Does it support real-time validation on forms?

Definitely. You can use the single validation method to verify emails instantly as users submit your web forms.

You're just one click away from clean email lists.

Start verifying your email addresses instantly and improve your campaign deliverability

* No credit card required