How to restrict an AI chatbot to specific URLs only
Three controls, three jobs
Each control solves a different problem.
| Control | What it does | Where |
|---|---|---|
| Crawl rules | Decide which pages are indexed at all | Crawl settings |
| Audience | Keep a source off public channels | Each source's settings |
| Workspaces | Give different audiences different knowledge | Workspace switcher |
With strict mode on (the default), the agent says it does not know when nothing relevant was indexed, so a page you never crawled cannot leak into an answer.
1. Limit the crawl
Open the crawl settings for your website source:
- Include rules. Only URLs matching these patterns are crawled, for example
/docs/*and/help/*. - Exclude rules. URLs matching these are skipped even if an include rule matches, for example
/admin/*or/blog/*. - Maximum pages. A ceiling on how many pages one crawl takes.
- CSS selector. Index only the main content area, such as
.main-article, so menus and footers are not learned. - Use sitemap. Turn off if your sitemap lists pages you do not want considered.
Rules apply when pages are discovered, so a page that does not match is not fetched or indexed. One exception: if no page matches at all, AskVault still indexes the starting URL so the source is not empty.
2. Remove pages that slipped in
Rules only affect future crawls. If unwanted pages were indexed earlier, select them in the Knowledge list and delete them. Re-check after the next recrawl.
3. Keep internal sources off public channels
Each knowledge source has an Audience: public (the default) or internal. An internal source is removed from retrieval on the widget, the hosted page and the public API before the model sees anything, so the agent cannot quote it there.
Set it in the source's settings. There are no custom audiences or per-user rules; it is one switch.
4. Different knowledge for different customers
A source is visible to everyone who reaches that workspace's public channels. If each of your customers should only get answers from their own material, give each one a workspace:
- One workspace per customer, with crawl rules limited to that customer's pages.
- That workspace's widget token on that customer's pages.
- Identity verification so the agent knows which signed-in user it is talking to.
Starter includes 2 workspaces, Growth 5 and Business 15. Growth+
Prompt rules are a backstop, not a wall
You can add "Only answer questions about our product and policies" to the system prompt. It helps with tone, but a determined visitor can talk a model round. Rely on what is indexed, not on wording.
Test your restrictions
- Crawl test. Ask a question only an excluded page could answer. The agent should say it does not know. If it answers, find and delete that page.
- Audience test. Mark a source internal, then ask about it on the widget. The agent should not use it.
- Sources test. Ask in the chat playground and open the answer's sources to see which source it came from. The playground has no document picker, so it tests the whole workspace.
Common pitfalls
Relying on the system prompt alone. Prompt instructions can be bypassed. Crawl rules and audience cannot.
Tightening rules without deleting old pages. Pages indexed before the change stay until you delete them.
Expecting per-visitor document filtering. It does not exist today. Use separate workspaces.
FAQ
Can I restrict the bot to certain types of questions?
Partly. Index only what you want answered, keep strict mode on, and add a scope line to your prompt.
What happens when someone asks outside the scope?
With strict mode on, the agent says it does not have that information and can offer a person.
Do restrictions change how the widget looks?
No. They only change what the agent knows.
Does this work on WhatsApp and other channels?
Yes. Crawl rules and audience apply on every channel the workspace serves.
Related guides
- Install the AskVault widget on any website
- Identity verification setup
- Audience
- How to scrape a JavaScript-rendered website
- What is RAG?