Nmap2Notion is a simple Python-based tool that connects Nmap (a popular network scanner) with Notion.
It helps security teams, sysadmins, and developers track network scan results directly in Notion for easy monitoring and reporting.
- CIDR Scan: Scans a full subnet, adds alive IPs with their open ports into Notion, and sets the status to
Not started. - Single IP Scan: Updates the IP’s status in Notion (
Not started → In progress → Done) with a timestamp. If the IP does not exist in Notion, the scan runs, but no update is made in Notion.
-
Python 3.8+
-
Nmap installed
-
Python libraries:
pip install -r requirements.txt
-
A Notion account with:
- Integration Secret (from Notion Integrations)
- Database ID (from the Notion database link)
sudo apt update
sudo apt install nmap -ybrew install nmap- Download from Nmap official site.
- Run the installer and make sure to check "Add Nmap to PATH".
To verify installation:
nmap --versionYour Notion database should include the following properties:
-
IP Address → Title
-
Ports → Multi-select
-
Open Count → Number
-
Monitoring Status → Status with values:
- Not started
- In progress
- Done
-
Last Checked → Date
-
Clone the repository:
git clone https://github.com/yourusername/nmap2notion.git cd nmap2notion -
Install dependencies:
pip install -r requirements.txt
-
On first run, the script will ask for:
- Notion Integration Secret
- Database ID
If you choose to save them, they will be stored in:
~/.notion_config.json
python3 nmap_to_excel.py 192.168.1.0/24- Performs ping scan → port scan.
- Saves alive IPs, open ports, and counts into Notion with status
Not started.
python3 nmap_to_excel.py 192.168.1.10- If IP exists in Notion → updates status:
Not started → In progress → Done, updates Last Checked. - If not in Notion → runs scan only, no database update.
- Ensure your Notion integration has access to the database (Share → Invite → your integration).
- Nmap does the scanning — this tool parses results and syncs them to Notion.
MIT License – free to use, modify, and share.