In the course of an investigation, we would often like to find all contact information, such as emails or phones from a company, both for marketing / sales purposes and as investigative leads. Collecting them manually can be quite time-consuming, and does not guarantee that the full list of emails can be found.
Thankfully there are a variety of tools that can help us with this task:
We can use the site: & intext: Google operators to find all pages containing emails that were indexed by Google. For example:
site:tesla.com intext:"@tesla.com"
In some cases, we’d be able to see the email itself on the search results page.

A better solution is to use an extension that automatically detects and scrapes email addresses from the webpage and enables you to extract them as a CSV.
Recommended extensions for email addresses extracting are:
- Email Extractor – discovers all the email addresses in the website you are visiting. Then, you can export all the emails in a CSV file
- Phantom Buster – Automatically extract emails from any website. Scrape email addresses on automatic and download to results to a spreadsheet.
Another cool option is to use the Bulk Email Extractor web app, which allows you to enter a list of URLs and scan all of them for email addresses that can be extracted to Excel.
Finally, you can also try completing the task using a code that runs on the HTML file and collects all email formats it finds. After the page you want to explore is loaded, right-click > inspect (or f12 / ctrl+shift+i ) to open the developer tools. Go to the console at the bottom of the developer tools and copy the following code:
var allelements = document.body.getElementsByTagName("*"); var rege = new RegExp("(^[a-zA-Z0-9_.+-]+@[a-zA-Z0-9-]+.[a-zA-Z0-9-.]+$)"); for (var i = 0; i < allelements.length; i++) { if (rege.test(elems[i].innerHTML)) { console.log(elems[i].innerHTML); } }
The above code will run on all the elements in the page’s HTML file, look for the elements in an email address format, and print them out.

3 thoughts on “How to Extract All Email Addresses From a Website”
I would like to thank you for the efforts you’ve put in penning this website.
I’m hoping to see the same high-grade blog posts by you in the future as well.
In fact, your creative writing abilities has motivated me to get my own,
personal website now 😉
I have read so many articles or reviews concerning the blogger lovers however this post is genuinely
a pleasant post, keep it up.
Wow, awesome blog layout! How long have you been blogging for?
you make blogging look easy. The overall look of your website is magnificent, let alone the content!
Comments are closed.