A simple and responsive AI chatbot built using HTML, CSS, and JavaScript. The chatbot allows users to send messages and receive AI-generated responses through an API.
- 💬 User and AI chat messages
- 🤖 AI-generated responses
- 📱 Responsive chat interface
- ⌨️ Simple message input and send button
- 🔌 API-based AI integration
- HTML5
- CSS3
- JavaScript
- Fetch API
- AI API
- Vercel
AI-Chatbot/
│
├── index.html
├── style.css
├── index.js
├── img/
│ ├── head-background.jpg
│ ├── logo.jpg
│ └── ai.jpg
├──favicon.ico
└── README.md
This project requires an AI API key to generate responses.
You must create your own API key from your preferred AI API provider and add it to your JavaScript code.
Example:
const API_KEY = "YOUR_API_KEY";Then use your API key in the API request.
- Clone this repository:
git clone https://github.com/imakasx/my-ai-chatbot.git-
Open the project folder.
-
Add your own API key in
index.js. -
Open
index.htmlusing Live Server or another local development server. -
Start chatting with the AI 🤖
User enters message
↓
JavaScript gets input.value
↓
Message is displayed in chat
↓
API request is sent
↓
AI generates response
↓
Response is received
↓
AI message is displayed
screenshot of chatbot here:
If you found this project useful, consider giving the repository a ⭐ on GitHub.