Notion Integration

Import your Notion pages and documentation into Contextium. Connect once and import entire page hierarchies in minutes.

Notion Integration

Import your Notion documentation into Contextium and make it accessible to AI assistants.

What gets imported: All pages, subpages, content blocks, images, and formatting

Time required: 5-10 minutes for initial setup, then 2 minutes per import


What You'll Learn

By the end of this guide, you'll be able to:

  • Create a Notion integration and get your API token
  • Connect Notion to your Contextium workspace
  • Grant page access to the integration
  • Import Notion pages into Contextium projects
  • Understand how the import structure works

Prerequisites:

  • A Notion account with admin access to the workspace you want to import from
  • A Contextium account with an active workspace

Why Import from Notion?

The Problem

Your team's documentation lives in Notion, but AI assistants can't access it directly. You end up:

  • Copy-pasting content for every AI question
  • Maintaining duplicate documentation
  • Losing context and formatting
  • Missing updates when Notion content changes

The Solution

Import your Notion pages into Contextium once, and:

  • AI assistants can access your docs via MCP integration
  • Full-text search across all your documentation
  • Version control and change tracking
  • Maintain a single source of truth

Step 1: Create a Notion Integration

First, you'll create an internal integration in Notion to allow Contextium to read your pages.

Create the Integration

  1. Go to Notion Integrations
  2. Click + New integration
  3. Fill in the details:
    • Name: Contextium (or any name you prefer)
    • Associated workspace: Select your workspace
    • Logo: (Optional) Upload a logo
  4. Under Capabilities, ensure these are enabled:
    • Read content
    • Read comments (optional)
    • Update content (not needed)
    • Insert content (not needed)
  5. Click Submit

Get Your Integration Token

After creating the integration:

  1. You'll see a page with Internal Integration Token
  2. Click Show to reveal the token
  3. Click Copy to copy it to your clipboard
  4. Keep this token secure - treat it like a password

The token looks like this:

secret_abc123xyz789...

Security Note: Never share this token publicly or commit it to version control. Anyone with this token can read your Notion pages.


Step 2: Connect Notion to Contextium

Now you'll add your Notion integration token to Contextium.

Add the Integration

  1. Log in to Contextium
  2. Navigate to SettingsConnections (or click your avatar → SettingsConnections)
  3. Find the Notion section
  4. Click Connect Notion
  5. Paste your integration token in the API Token field
  6. Click Save or Connect

You should see a green checkmark ✓ indicating Notion is connected.

Verify Connection

To verify the connection worked:

  1. Go to Projects page
  2. Click the Import dropdown button
  3. You should see From Notion as an enabled option (not grayed out)

If "From Notion" shows "Connect →" instead, the connection didn't work. Check that:

  • You copied the entire token (starts with secret_)
  • You pasted it without extra spaces
  • The token hasn't been revoked in Notion

Step 3: Grant Page Access

This is the most commonly missed step!

By default, your Notion integration can't see any pages. You must explicitly grant access to the pages you want to import.

Share Pages with Integration

For each page (or parent page) you want to import:

  1. Open the page in Notion
  2. Click the Share button (top right)
  3. Click Invite
  4. Search for your integration name (e.g., "Contextium")
  5. Select the integration from the dropdown
  6. Click Invite

The integration will now appear in the "Shared with" section of that page.

Grant Access to Parent Pages

Pro tip: If you grant access to a parent page, the integration automatically has access to all its subpages.

Example:

📄 Engineering Docs (← Share integration with this page)
  ├─ 📄 Backend API
  │  ├─ 📄 Authentication
  │  └─ 📄 Rate Limiting
  ├─ 📄 Frontend
  └─ 📄 Database Schema

By sharing "Engineering Docs" with the integration, it can access all nested pages underneath.

Verify Access

To check which pages your integration can access:

  1. Go back to Notion Integrations
  2. Click on your integration (e.g., "Contextium")
  3. Scroll down to see Pages the integration has access to

Step 4: Import Pages into Contextium

Now you're ready to import your Notion pages.

Start an Import

  1. In Contextium, go to Projects
  2. Click the Import dropdown button
  3. Select From Notion
  4. The import modal opens

You should see:

  • ✅ Green banner: "Using your connected Notion integration"
  • A URL input field for the Notion page

Get Your Notion Page URL

  1. In Notion, open the page you want to import
  2. Copy the page URL from your browser's address bar

The URL looks like:

https://www.notion.so/My-Documentation-abc123def456

Paste URL and Import

  1. Paste the Notion page URL into the Notion Page URL field
  2. Click Start Import

The import process begins:

  • Status changes to "Importing from Notion..."
  • This may take a few minutes depending on page size
  • The modal shows a loading spinner

Import Complete

When finished, you'll see:

  • Import Successful!
  • Stats showing:
    • Files Created - Number of pages imported
    • Folders Created - Always 0 (see Understanding Import Structure below)
    • Images Imported - Number of images embedded
  • A View Project button to see your imported content

Click View Project to open the newly created project.


Understanding Import Structure

Contextium imports Notion pages with a flat structure - all pages become files at the root level, with no nested folders.

Why Flattened?

Contextium is optimized for AI connectivity, not visual hierarchy. A flat structure:

  • Makes all content immediately searchable
  • Simplifies AI context retrieval
  • Avoids deep nesting that's hard to navigate
  • Works better with full-text search

How Pages Map to Files

Your Notion hierarchy:

📄 Product Documentation (root)
  ├─ 📄 Getting Started
  ├─ 📄 Features
  │  ├─ 📄 Authentication
  │  └─ 📄 Search
  └─ 📄 API Reference

Becomes in Contextium:

Project: "Notion Import"
├─ index.md (Product Documentation - root page)
├─ getting-started.md
├─ features.md
├─ authentication.md
├─ search.md
└─ api-reference.md

All files are at the root level, no folders.

File Naming

  • Root pageindex.md
  • Other pages → Filename based on page title (lowercase, hyphens, .md extension)
  • Special characters are replaced with hyphens
  • Filenames are truncated to 200 characters max

Multiple Imports

Each import creates a new project:

  • First import: Notion Import
  • Second import: Notion Import (1)
  • Third import: Notion Import (2)
  • And so on...

This prevents naming conflicts and lets you import different Notion hierarchies separately.


What Gets Imported

Supported Content

Text blocks:

  • Paragraphs
  • Headings (H1, H2, H3)
  • Lists (bulleted, numbered)
  • Quotes
  • Code blocks (with syntax highlighting)
  • Callouts/alerts

Media:

  • Images (uploaded to Contextium)
  • Image captions

Formatting:

  • Bold, italic, code, strikethrough
  • Links (internal and external)
  • Dividers

Structure:

  • All subpages (nested pages)
  • Page properties (preserved as metadata)

Limitations

Not imported:

  • Databases (shown as placeholder text)
  • Synced blocks (imported as regular content, not synced)
  • Some embeds (converted to links)
  • Comments (not imported)
  • Page history (only current version)

Not synced:

  • Changes in Notion don't auto-update in Contextium
  • To get updates, re-import the page (creates new project)

Managing Your Connection

Update API Token

If you need to change your Notion token:

  1. Generate a new token in Notion (or use existing one)
  2. Go to Contextium SettingsConnections
  3. Click Disconnect next to Notion
  4. Click Connect Notion again
  5. Paste new token
  6. Click Save

Disconnect Notion

To remove the Notion integration:

  1. Go to SettingsConnections
  2. Find Notion section
  3. Click Disconnect
  4. Confirm disconnection

This removes the stored token from Contextium. You can reconnect anytime.

Revoke Access in Notion

To completely revoke Contextium's access:

  1. Go to Notion Integrations
  2. Click on your integration (e.g., "Contextium")
  3. Click Delete integration (bottom of page)
  4. Confirm deletion

This permanently removes the integration and invalidates the token.


Troubleshooting

"Notion integration not connected"

Problem: Import modal shows warning about connecting Notion first.

Solution:

  1. Go to SettingsConnections
  2. Check if Notion shows as connected (green checkmark)
  3. If not connected, add your token (see Step 2)
  4. If already connected, try disconnecting and reconnecting
  5. Clear your browser cache and hard refresh (Cmd+Shift+R / Ctrl+Shift+R)

"No token provided" error

Problem: Import fails with "No token provided" error.

Cause: Token isn't properly saved or session expired.

Solution:

  1. Log out of Contextium
  2. Log back in
  3. Go to SettingsConnections
  4. Disconnect Notion
  5. Reconnect with your token
  6. Try importing again

"Page not found" or "Access denied"

Problem: Import fails saying it can't access the Notion page.

Cause: Integration doesn't have permission to read the page.

Solution:

  1. Open the Notion page you're trying to import
  2. Click ShareInvite
  3. Add your integration (e.g., "Contextium")
  4. Wait 30 seconds for permissions to propagate
  5. Try importing again

Check access:

Import stuck at "Importing..."

Problem: Import modal shows "Importing from Notion..." for more than 5 minutes.

Possible causes:

  • Very large page hierarchy (100+ pages)
  • Network timeout
  • API rate limiting

Solution:

  1. Wait up to 10 minutes for large imports
  2. If still stuck, refresh the page
  3. Check Projects to see if project was created
  4. Try importing a smaller subset of pages
  5. Contact support if issue persists

Images not showing

Problem: Imported files show image placeholders or broken images.

Cause: Image upload failed during import.

Solution:

  • Images are downloaded from Notion and re-uploaded to Contextium
  • If upload fails, you'll see a broken image link
  • Try re-importing the page
  • Check that Notion images are publicly accessible

Invalid URL error

Problem: Import fails with "Invalid Notion URL" error.

Cause: URL format not recognized.

Valid URL formats:

✅ https://www.notion.so/Page-Name-abc123def456
✅ https://www.notion.so/workspace/Page-Name-abc123def456
✅ https://notion.so/Page-Name-abc123def456

Invalid formats:

❌ notion://... (desktop app links)
❌ https://notion.so/ (homepage)
❌ Page URLs without the hash (abc123...)

Solution:

  1. Open the page in Notion web app (not desktop app)
  2. Copy the full URL from browser address bar
  3. Paste complete URL (including the abc123... hash)

Content formatting issues

Problem: Imported content looks different from Notion.

Cause: Some Notion formatting doesn't translate to Markdown.

Known differences:

  • Callout icons may be simplified
  • Some colors lost (converted to semantic styles)
  • Tables may have different styling
  • Synced blocks appear as regular content

These are expected - Markdown has different capabilities than Notion's block editor.


Best Practices

Before Importing

Organize in Notion:

  • Create a clear parent page for documentation you want to import
  • Remove outdated pages
  • Ensure page titles are descriptive
  • Add page descriptions for context

Test with a small page first:

  • Import a single page to verify the process
  • Check formatting and content
  • Then import larger hierarchies

Security

Token management:

  • Store token securely (password manager)
  • Don't share token with others
  • Revoke and regenerate if compromised
  • Use separate integrations for different projects

Access control:

  • Only grant integration access to pages you want to import
  • Don't share entire workspace with integration
  • Review integration permissions quarterly
  • Remove integration access from sensitive pages

Regular Imports

Keep Contextium updated:

  • Re-import pages when you make major changes in Notion
  • Each import creates a new project (old one stays)
  • Delete old import projects to avoid duplicates
  • Consider Contextium as a snapshot, not a live sync

Naming strategy:

  • Use descriptive project names after import
  • Rename "Notion Import" to something meaningful
  • Add descriptions to projects
  • Tag projects by department or topic

Advanced Usage

Importing Multiple Hierarchies

You can import different sections of your Notion workspace separately:

Example:

Import #1: Engineering docs → Project: "Engineering Docs"
Import #2: Product specs → Project: "Product Specs"
Import #3: Company handbook → Project: "Handbook"

Each becomes a separate Contextium project.

Combining with Other Sources

Contextium projects can mix content from multiple sources:

  • Import from Notion
  • Upload markdown files
  • Add manually created files
  • All searchable together

Using with MCP Integration

After importing, connect AI assistants via MCP:

  1. Import Notion pages to Contextium
  2. Set up MCP integration
  3. AI assistants can now search your imported Notion content
  4. Ask questions like: "Based on our product docs, how does authentication work?"

AI gets answers from your imported Notion documentation.


Next Steps

Now that you've imported your Notion documentation:


Need Help?

If you run into issues:

  1. Check this guide's Troubleshooting section
  2. Visit Community Support
  3. Email support@contextium.io
  4. Check our status page for service issues

Common resources: