How to Add an AI Chatbot to Your Website Using Your Own Documents (2026 Guide)
Many businesses install a chatbot and only later think about document structure. That order leads to weak answers, confusion, and inconsistent results. With Docurest, the correct production flow is different.
The right sequence is: Create the widget → Define domain context → Upload documents → Generate embed code → Launch → Test. Following this structure ensures your assistant is grounded, secure, and business-ready.
Step 1: Create the Widget First
In Docurest, the widget defines the operational context of your AI assistant. It links your domain, language, visibility settings, and document scope. Documents should only be uploaded after the widget is configured.
- Open Embedding & Widgets
- Add your domain
- Create a new AI Widget key
- Configure visibility and language
Step 2: Upload & Ingest Documents
After the widget exists, upload documents into the selected context. This guarantees that ingestion is tied to the correct assistant environment.
- Select index and namespace
- Upload PDFs, DOCX, TXT, or MD files
- Configure chunk size and overlap
- Start ingestion
Step 3: Copy the Dashboard-Generated Embed Code
Once your widget is created, Docurest generates a ready-to-use embed snippet. You do not edit script URLs. You simply copy the snippet provided in the dashboard.
- Click “Copy Snippet”
- Paste into your website footer or layout file
- No modification required
Step 4: Assistant Live on Your Website
After embedding the generated code, your assistant appears on your website. It responds strictly from uploaded documents and respects the configured domain context.
Security & Governance Checklist
- Create separate widgets for staging and production
- Restrict document uploads to approved team members
- Remove secrets or sensitive credentials from documents
- Test refusal behavior before public launch
Conclusion
A business-grade AI chatbot is not just about installation. It is about structure and operational order. Create the widget first. Define context. Then ingest documents. Finally, deploy the dashboard-generated embed snippet.
Start a 30-day trial of Docurest and deploy a document-grounded AI assistant using the correct production workflow.