Migrating from Notion to DenchClaw
Migrating from Notion to DenchClaw: export databases as CSV, import to DuckDB, map Notion properties to CRM fields, and decide what stays in Notion vs moves over.
Migrating from Notion to DenchClaw
Notion is a great wiki. It's a mediocre CRM. If you've been using Notion databases to track contacts, deals, or pipeline — you've probably felt the friction: slow queries, no real aggregations, no AI assistance for lookups, and clunky rollup formulas.
DenchClaw is purpose-built for CRM. Contacts, companies, deals, and activities live in a local DuckDB database. You query it in natural language. It runs on your machine. And the parts that actually work well in Notion (documentation, templates, knowledge base) you can keep there.
Here's how to migrate.
What to Move, What to Keep#
First, decide what's actually CRM data vs what's knowledge base content.
Move to DenchClaw:
- Contact/people databases (names, emails, companies, statuses)
- Deal or pipeline databases (stages, values, owners)
- Company/account databases
- Activity logs (calls, meetings, notes linked to contacts)
- Lead tracking databases
Keep in Notion:
- Meeting notes and documentation
- Company wikis and SOPs
- Product specs and roadmaps
- General knowledge base content
- Templates that aren't CRM records
If you're using Notion as a full replacement for a CRM, the databases are what need to move. The pages and wikis can stay.
Step 1: Export Notion Databases as CSV#
Notion's CSV export is clean and reliable for database content.
Export a single database#
- Open the Notion database (any view — table view is easiest)
- Click the ... menu in the top right
- Select Export
- Choose Markdown & CSV or just CSV
- Check Include subpages if relevant
- Click Export — you'll get a zip file
Inside the zip, you'll find:
- A
database-name.csvfile with all your database rows - A
database-name/folder with individual page exports (for rows that have page content)
Export all databases at once#
For full workspace export:
- Go to Settings → Workspace → Export
- Choose Export all workspace content
- Format: Markdown & CSV
- This exports everything — databases as CSVs, pages as markdown files
Step 2: Clean the Exported CSV#
Notion CSV exports have a few quirks to address before importing.
# Preview the exported file
head -3 "Contacts.csv"
# Output example:
# Name,Email,Company,Status,Tags,Created,Last edited
# "Sarah Chen","sarah@acme.com","Acme Corp","Active","vip,warm","2024-01-15","2024-03-10"Common issues:
Multi-select fields: Exported as comma-separated values inside the cell. DenchClaw handles these natively.
Relations (linked pages): Export as the page title of the linked record. You'll need to re-create relations manually after import (same as Airtable).
Formulas: Export as their computed value at export time. Re-create the logic in DuckDB if needed.
Notion page URLs: Each row gets a Notion URL column. You can drop this field on import.
Date formatting: Notion exports dates as @January 15, 2024 or ISO format depending on the field. Clean them up:
# Convert Notion's @ date format to ISO
sed -E 's/@([A-Z][a-z]+ [0-9]+, [0-9]+)/\1/g' contacts.csv > contacts_clean.csvOr handle it in Python:
import pandas as pd
from dateutil import parser
df = pd.read_csv('Contacts.csv')
# Parse Notion date format
df['Created'] = df['Created'].apply(lambda x: parser.parse(x.replace('@', '')) if pd.notna(x) else None)
df['Created'] = pd.to_datetime(df['Created']).dt.strftime('%Y-%m-%d')
df.to_csv('contacts_clean.csv', index=False)Step 3: Map Notion Properties to DenchClaw Fields#
| Notion Property Type | DenchClaw Field Type | Notes |
|---|---|---|
| Title | text (name) | First field, always the entry name |
| Text | text | Direct mapping |
| Number | number | Direct mapping |
| Select | select | Direct mapping |
| Multi-select | multi_select | Comma-separated |
| Status | select | Map stages to DenchClaw status |
| Date | date | Normalize format first |
| Person | text | Import as name string |
| Files & media | file | Download files first |
| Checkbox | boolean | Direct mapping |
| URL | url | Direct mapping |
| Direct mapping | ||
| Phone | phone | Direct mapping |
| Formula | computed | Re-create in DuckDB |
| Relation | relation | Manual post-import |
| Rollup | computed | Re-create with SQL |
| Created time | created_at | Auto-set |
| Created by | text | Import as plain text |
| Last edited time | updated_at | Auto-set |
| Last edited by | text | Import as plain text |
Create the DenchClaw fields before importing#
# Create fields on the people object to match your Notion schema
npx denchclaw field create --object people --name "notion_id" --type text
npx denchclaw field create --object people --name "tags" --type multi_select
npx denchclaw field create --object people --name "lead_score" --type number
npx denchclaw field create --object people --name "last_contacted" --type dateStep 4: Import the CSV#
npx denchclaw import csv \
--file contacts_clean.csv \
--object people \
--field-map \
"Name:name" \
"Email:email" \
"Company:company_name" \
"Status:status" \
"Tags:tags" \
"Phone:phone" \
--skip-fields "Last edited,Created by,Notion URL" \
--dedupe emailFor the deals/pipeline database:
npx denchclaw import csv \
--file pipeline_clean.csv \
--object deals \
--field-map \
"Deal Name:name" \
"Stage:status" \
"Value:value" \
"Close Date:close_date" \
"Contact:contact_name" \
--dedupe nameVerify the import#
-- Check counts match your Notion database
SELECT COUNT(*) FROM v_people;
SELECT COUNT(*) FROM v_deals;
-- Check for any empty names (indicates mapping issue)
SELECT COUNT(*) FROM v_people WHERE name IS NULL OR name = '';
-- Preview imported data
SELECT name, email, company_name, status FROM v_people LIMIT 10;Step 5: Import Notion Pages as DenchClaw Documents#
Notion pages (not database rows) can be imported as DenchClaw documents. This is useful for notes linked to contacts or companies.
Export pages as Markdown#
When you export your Notion workspace, pages come out as .md files. DenchClaw's document system accepts markdown.
# Import a Notion page export as a document
npx denchclaw document import \
--file "Meeting Notes/2024-Q1-Review.md" \
--title "Q1 Review Meeting Notes" \
--link-object people \
--link-entry-name "Sarah Chen"For bulk page imports:
# Import all markdown files from a Notion export folder
for f in "Notion Export/Meeting Notes/"*.md; do
npx denchclaw document import --file "$f" --category "Meeting Notes"
doneStep 6: Handle Notion's Nested Page Structure#
Notion's hierarchy (pages inside pages inside pages) doesn't have a direct equivalent in DenchClaw. Here's how to flatten it sensibly:
Option A: Import pages as documents with categories
Flatten the hierarchy into categories. A page called Customers > Acme Corp > Meeting Notes > Q1 becomes a document with the category path preserved.
Option B: Link documents to CRM entries For customer-specific pages, link each document to the corresponding company or person entry in DenchClaw.
Option C: Keep in Notion Honestly, if the pages are documentation and not CRM data, leave them in Notion. DenchClaw's strength is structured CRM data, not nested documentation trees. There's no shame in keeping your wiki where it works.
Step 7: Recreate Notion Templates#
Notion templates for new database entries map to DenchClaw's entry templates.
# Create a default template for new deals
npx denchclaw template create \
--object deals \
--name "Standard Deal" \
--defaults '{"status": "Lead", "probability": 20, "currency": "USD"}'For more complex templates with default field values:
npx denchclaw template create \
--object people \
--name "New Lead" \
--defaults '{
"status": "Lead",
"source": "Inbound",
"lead_score": 0,
"next_action": "Initial outreach"
}'Migration Timeline#
| Notion Setup | Time Estimate |
|---|---|
| 1 database, < 500 rows | 1-2 hours |
| 2-3 databases, 500-2,000 rows | Half day |
| Large workspace, many databases | 1-2 days |
| Complex relations and rollups | Add 2-4 hours |
FAQ#
Can I keep using Notion for some things and DenchClaw for others? Yes, and this is often the right answer. Notion excels at documents, wikis, and knowledge management. DenchClaw excels at structured CRM data with AI queries. Many teams use both.
What happens to Notion's @mentions of pages in my database? They export as plain text (the page title). The linkages are lost. For important cross-references, recreate them as relation fields in DenchClaw or notes in a text field.
How do I handle Notion database views (filters and sorts)?
Recreate them as DenchClaw views using npx denchclaw view create. You can apply the same filters and sort logic.
Can I import Notion calendar database entries? Yes. If your calendar database has a date field, import it normally and then create a calendar view in DenchClaw grouped by that date field.
What about Notion AI features I'm using? DenchClaw has its own AI (natural language queries, enrichment). You won't miss Notion AI for CRM tasks — querying DenchClaw in plain English via Telegram or Discord is faster than Notion AI for structured data lookups.
Ready to try DenchClaw? Install in one command: npx denchclaw. Full setup guide →
