Has Invalid Email Address¶
This Condition is located on the Contact Info category tab in Search Builder. It checks whether a person has an email address that is not in a valid format and returns True or False.
The system validates the format of both the primary and secondary email addresses on a person’s record. It does not matter whether the email address is flagged as Active or Inactive – this Condition is checking only the format of the address itself.
When set to True, the search returns people who have at least one email address (primary or secondary) that is not correctly formed.
When set to False, the search returns people whose email addresses are all in a valid format. This also includes people who have no email address on file, because a blank email is not considered invalid.
Note
The email format check looks for a properly structured address: characters before the @ symbol, a domain name after the @, and a valid extension (such as .com, .org, or .net). Extensions must be between 2 and 4 characters.
Examples of email addresses that would be flagged as invalid:
johnAOL.com– missing the @ symbolmary@comcast.nnnet– too many characters in the extensionalfred@hotmail.c0m– a zero in place of the letter “o”jane@church.– missing the extension entirely
Filtering a Mailing Group¶
You can use Has Invalid Email Address set to False to limit a mailing list to only people with properly formatted email addresses. This is helpful when you are building a search to send email to a specific group and want to exclude anyone with a bad address.
Example
To send email to members of an involvement while excluding bad email addresses:
Go to Search > Search Builder > New Search.
Add the Condition Is Member Of (Enrollments tab) and select your involvement (for example, Weekly Newsletter).
Add the Condition Has Invalid Email Address (Contact Info tab), set the Comparison to Equal, and select the Value False.
Make sure the group is set to Match All so both conditions must be met.
Click Run to view the results.
The results will include only people enrolled in that involvement whose email addresses are in a valid format.
Search Builder setup: Is Member Of combined with Has Invalid Email Address = False to filter a mailing group to only those with valid email addresses.¶
Identifying Which Email Address Is Invalid¶
Because Has Invalid Email Address checks both the primary and secondary email addresses together, it will tell you that someone has an invalid email but not which one. To narrow this down, combine it with the Email Address - Primary or Email Address - Secondary Condition on the Personal tab to focus on one email field at a time.
Finding invalid primary emails¶
This search finds people who have a primary email address and at least one invalid email on their record.
Add Has Invalid Email Address (Contact Info tab), set to Equal True.
Add Email Address - Primary (Personal tab), set the Comparison to Not Equal and leave the text field blank. This limits results to people who have something in the primary email field.
Set the group to Match All.
Search Builder setup to find people who have a primary email address and at least one invalid email on their record.¶
Finding invalid secondary emails¶
Run a separate search to focus on the secondary email field.
Add Has Invalid Email Address (Contact Info tab), set to Equal True.
Add Email Address - Secondary (Personal tab), set the Comparison to Not Equal and leave the text field blank. This limits results to people who have something in the secondary email field.
Set the group to Match All.
Search Builder setup to find people who have a secondary email address and at least one invalid email on their record.¶
Tip
Because this Condition checks both email fields at once, a person with both a primary and secondary email may appear in either search if one of their addresses is invalid. Review the results for each search and look at the actual email addresses on the person’s record to determine which one needs to be corrected.
Cleaning Up Invalid Emails¶
Once you have identified people with invalid email addresses, you can use Tags and the Batch Update Fields tool to clean up your data.
Run one of the searches above to find people with invalid emails.
Add the results to a Tag (for example, Invalid Primary Emails or Invalid Secondary Emails). You can create separate Tags for primary, secondary, or both depending on what you find.
Review the people in each Tag and correct any email addresses that can be fixed.
For email addresses that cannot be corrected and need to be removed, use the Batch Update Fields tool to clear the email field for everyone in the Tag at once.
Note
The system does validate email addresses before sending and will skip addresses that are clearly malformed (such as those missing the @ symbol). However, the email sending system uses a different validation method than this Search Builder Condition, so some addresses flagged here may still receive email. This Condition is primarily a data cleanup tool to help you find and correct email addresses that may not be in the standard format.
