← Back to demo

Embed the widget in minutes.

Paste the script below before the closing </body> tag on your website. Replace https://YOUR-WIDGET-DOMAIN.example with the public URL where this widget project is hosted. The proxy then sends messages to the configured n8n webhook.

<script
  src="https://YOUR-WIDGET-DOMAIN.example/n8n-chat-widget.js"
  data-api-base="https://YOUR-WIDGET-DOMAIN.example"
  data-title="Workflow assistant"
  data-greeting="Ask the workflow anything."
></script>

Important: Keep data-api-base pointed at this widget deployment, not directly at the n8n URL. The server-side proxy handles CORS, response normalization, and the session payload sent to n8n.

Optional configuration attributes are data-title, data-greeting, and data-launcher-label. The n8n URL is configured with N8N_CHAT_URL; the project already defaults to the webhook you supplied.