Build Your First AI Chatbot0% done
← PrevFinish ✓
Lesson 6 of 6~2 min read

Lesson 5 — Deploying and Sharing

Your chatbot is ready. Now make it accessible to real users.

Lesson 5 — Deploying and Sharing

Your chatbot is ready. Now make it accessible to real users.

Step 1: Move your API key out of the HTML

Before deploying, you need to protect your key. The cleanest approach for a quick deploy:

Ask Claude: *"Refactor my chatbot so the API call goes through a serverless function (Vercel Edge Function or Netlify Function) instead of directly from the browser. The function should read the API key from an environment variable called ANTHROPIC_API_KEY. Keep the UI in index.html."*

Claude will give you a two-file setup: your UI + a small server function. This takes 5 minutes to set up and is production-safe.

Step 2: Deploy to Vercel

  • Create a GitHub repo, push your files
  • Connect to Vercel, add `ANTHROPIC_API_KEY` in Environment Variables settings
  • Deploy — you get a live URL in 60 seconds
  • Step 3: Share and collect feedback

    Send the URL to 5 people. Watch how they use it. The conversations your bot has — especially where it fails — are pure gold. Each failure is a prompt engineering lesson.

    **What you can charge for this:** A customized chatbot for a local business (restaurant menu assistant, real estate FAQ bot, medical office intake bot) is worth $300–$2,000 to build plus $50–$200/month to maintain. You now have the skill to build and deliver it.

    ← PREVIOUSLesson 4 — Writing a Killer System PromptCOURSE COMPLETEBack to course overview ✓