Beginner10 min

Build a Chatbot in Voiceflow

A chatbot is just an automation that talks. Voiceflow lets you design one on a visual canvas without code, then publish it as a web widget you can drop on any site. We will build a small support bot that greets a visitor, answers from a knowledge base, and hands off to a human when stuck.

Step 1: Create the agent and add knowledge

Start a new agent in Voiceflow and open the Knowledge Base. Upload a PDF, paste text, or add a URL with your FAQ or help docs. This is what the bot will answer from, so it does not make things up.

Step 2: Design the conversation

On the canvas, drop a greeting message, then a Capture block to take the user's question, then an AI Response block set to answer from the Knowledge Base. Wire them in order. The AI block reads the question and pulls the answer from your uploaded docs.

Voiceflow - support bot flow
Agent
Hi! I am the Acme help bot. What can I help you with?
You
How do I reset my password?
Agent
Go to Settings, Security, then Reset password. You will get an email link that expires in 15 minutes. Want me to send it now?
You
Actually I need to talk to a person.
Agent
No problem, connecting you to a human agent now.
A minimal but complete support conversation.

Step 3: Add the human handoff

Add an Intent that triggers on phrases like talk to a human or speak to support. Route that intent to a message confirming handoff (later you can wire this to a live chat tool or an email). Always give people an exit; a bot that traps users is worse than no bot.

Step 4: Test and publish

Use the Test panel to chat with your bot and watch which blocks light up. When it answers cleanly, publish and copy the embed snippet into your site.

embed snippet
<script type="text/javascript">
  (function(d, t) {
    var v = d.createElement(t), s = d.getElementsByTagName(t)[0];
    v.onload = function() {
      window.voiceflow.chat.load({
        verify: { projectID: 'YOUR_PROJECT_ID' },
        url: 'https://general-runtime.voiceflow.com',
      });
    };
    v.src = 'https://cdn.voiceflow.com/widget-next/bundle.mjs';
    s.parentNode.insertBefore(v, s);
  })(document, 'script');
</script>
Test with real questions
Before you publish, ask the bot the five questions your customers actually ask most. If it nails those, you have already beaten most FAQ pages.

Hands-on tasks