PDF to Podcast transforms any PDF document into a podcast-ready audio episode using advanced AI text-to-speech (TTS) providers. Upload a PDF, select your preferred voice and provider, and receive an MP3 and a ready-to-use RSS feed for your podcast app.
Deploy this app to your favorite platform with one click:
Docker:
docker run -d -p 3000:3000 -e GEMINI_API_KEY=your_key ghcr.io/knoksen/pdf-to-podcast:latest
Fly.io:
fly launch --image ghcr.io/knoksen/pdf-to-podcast:latest
Create a .env.local file in the root with:
GEMINI_API_KEY=your_gemini_api_key
# Optionally:
# OPENAI_API_KEY=your_openai_key
# AZURE_API_KEY=your_azure_key
# AZURE_REGION=your_azure_region
# STORAGE_DIR=/path/to/episodes
GEMINI_API_KEY is required for Gemini-based TTS.Prerequisites:
Steps:
git clone https://github.com/knoksen/pdf-to-podcast.git
cd pdf-to-podcast
cp .env.local.example .env.local # then edit the file
npm install
npm run dev
Visit http://localhost:3000
/rss.xml in your podcast app.POST /api/episodes โ Upload a PDF and metadataGET /api/episodes โ List all podcast episodesGET /api/episodes/:id/audio โ Download episode audioGET /rss.xml โ Get podcast RSSExtending:
Add your own TTS provider by implementing a new provider in/services/tts/and updating the provider options.
Build your own image:
docker build -t pdf-to-podcast .
docker run -d -p 3000:3000 -e GEMINI_API_KEY=your_key pdf-to-podcast
npm run test
PRs and issues welcome! See CONTRIBUTING.md for details.
Open an issue or start a discussion.