Save cleaned web pages as structured Notion notes

They set up n8n to grab a page from a URL, extract readable text, summarize it with OpenAI, and store the output in Notion.

Done with n8nยท Intermediate

What they did
They wired together an n8n flow that starts with a webhook carrying a URL. From there, an HTTP Request node downloads the page, and a Code node strips out scripts, styling, and markup before cutting the text down to 8,000 characters. OpenAI then produces JSON with a title, summary, key insights, and tags, which the Notion node places into six mapped properties directly.
How it went
By cleaning the page first, the workflow shrank the input from about 60K tokens to under 4K. That brought costs down and made the summaries better. It still struggles with JavaScript-heavy single-page apps, which can return blank shell HTML, and some websites refuse the request.
Tips
Make sure the Notion database is shared with the n8n integration before testing, or the write may fail without warning. Adding a Mozilla/5.0 User-Agent header fixes most 403 responses.

Try it yourself with n8n

Set up an n8n workflow that begins when I send a [URL] through a form or webhook. It should retrieve the page, remove markup and other non-reading clutter, then hand the cleaned text to an AI model so it returns JSON with a title, a brief summary, main takeaways, and [number] tags. Use those fields to build a record in [database name] inside Notion, but stop first and show me the draft for approval before anything is saved or submitted. If the request is blocked, retry with a Mozilla/5.0 User-Agent header.

Fill in the [brackets]. Agents can make mistakes, so review anything before it is sent, paid or deleted.

Get 3 agent uses like this every morning

With the day's top AI news. Free, and one click to unsubscribe.