Free & beautiful REST API for hand-curated motivational, programming, life & wisdom quotes.
Built with FastAPI – automatic interactive docs, blazing fast, production-ready.
- Instant inspiration – one endpoint, endless motivation
- Categories (motivational, programming, funny, wisdom...)
- Multiple quotes in one call
- Interactive docs – try it live with Swagger UI
- Free deploy ready (Render, Railway, Vercel Python...)
- Great for: GitHub README widgets, Discord/Telegram bots, daily quote apps, blogs, portfolios
git clone https://github.com/voidethic/Random-Quote-API.git
cd Random-Quote-API
# Install
pip install -r requirements.txt
# Run locally
build.batNow open in your browser:
- http://localhost:8000/quote → one random quote
- http://localhost:8000/quote/5 → five random quotes
- http://localhost:8000/docs → beautiful interactive playground (Swagger UI)
| Method | Endpoint | Description | Example Response Fields |
|---|---|---|---|
| GET | / |
Welcome & API information | message, endpoints |
| GET | /quote |
One random quote | quote, author, category |
| GET | /quote/{count} |
Multiple random quotes (1–20) | quotes (array), count |
- Fork this repository
- Go to https://render.com → New → Web Service → Connect your GitHub repo
- Configure:
- Runtime: Python
- Build Command:
pip install -r requirements.txt - Start Command:
uvicorn main:app --host 0.0.0.0 --port $PORT
- Click Deploy → you’ll get a live URL like:
https://your-random-quote-api.onrender.com - Update this README with your live link!
Love quotes? Want to make this project even better?
- Add more curated quotes to
quotes.py - Suggest or implement new features:
- Search by author or category
- Voting/rating system
- Database support (SQLite/JSON file)
- Rate limiting
- Multiple categories filter
Steps:
- Fork & clone the repo
- Create your branch (
git checkout -b feature/add-quotes) - Commit your changes
- Push and open a Pull Request
Every great quote or improvement is welcome! 🌟
MIT License — free to use, modify, and share.
If this API gave you even one good quote today — drop a ⭐ !
Your star helps others discover it 🚀