I have developed a REST API for reading and searching across The Holy Bible. It is Open Source and available on GitHub.
The project is written in GO. And it is dockerized. The legacy PHP version can be found here, however, there is no search capability.
A live demo can be viewed here. I am hopeful to keep it hosted, and will scale accordingly, as long as I am financially able to do so.
If you’re working on a cool project and want to consume this API, please feel free to let me know!
Available Translations
- American Standard-ASV1901 (ASV)
- Bible in Basic English (BBE)
- Darby English Bible (DARBY)
- King James Version (KJV)
- World English Bible (WEB)
- Young’s Literal Translation (YLT)
- New International Version (NIV)
- New Living Translation (NLT)
Example In Action
I have made a web based search and cross reference tool, found here, that consumes this API.
API Specifications
Note: In order to get content for a specific translation, supply translation as a Query Parameter. For example, https://bible-go-api.rkeplin.com/v1/books/1/chapters/1/1001002?translation=ASV
List of Available Translations
GET https://bible-go-api.rkeplin.com/v1/translations
GET https://bible-go-api.rkeplin.com/v1/translations/[TranslationID]
List of Genres
GET https://bible-go-api.rkeplin.com/v1/genres
GET https://bible-go-api.rkeplin.com/v1/genres/[GenreID]
Content
GET https://bible-go-api.rkeplin.com/v1/books
GET https://bible-go-api.rkeplin.com/v1/books/[BookID]
GET https://bible-go-api.rkeplin.com/v1/books/[BookID]/chapters/[ChapterID]
GET https://bible-go-api.rkeplin.com/v1/books/[BookID]/chapters/[ChapterID]
GET https://bible-go-api.rkeplin.com/v1/books/[BookID]/chapters/[ChapterID]/[VerseID]
Cross References
GET https://bible-go-api.rkeplin.com/v1/verse/[VerseID]/relations
Search
GET https://bible-go-api.rkeplin.com/v1/search?query=[SearchTerm]
Docker Images
- GO API
- PHP API (Legacy API: does not include search endpoint)
- MariaDB Database
- ElasticSearch Database
28 Comments
Senaga
Big man. Please is there anyway I can add translation to the bible search, that is when someone wants to search the bible how can I modifify the API to accept translation?
Alicia
Thank you for this. My unfinished project is at https://the-way-417.web.app
I was using Bible Gateway, but they started forcing ads even on the printer-friendly version. This is a hobby for me, and I couldn’t implement the more complicated APIs. My tech stack is Ionic Angular on Firebase, so I have to fight CORS and figure out rxjs or upgrade my entire site to use signals. A year in my code is already deprecated. I look forward to switching to your API from Bible Gateway
Festus
Hi, can we make a query with a “to” verse?
example John 11vs20to35 (John 11:20-35).
Rob
No not at the moment. This would be a good feature to add though. Please consider creating an issue or pull request
Festus
Hi, Rob, thanks for making this available for free, and without the query limits imposed by other providers. Is there a way I can host this on my own server? to reduce calls to yours, If it’s possible. Thanks once more
Rob
Hey, thanks. Yeah, you can certainly host it yourself – check out this GitHub repository. It’s been a while since I fired it up from scratch, but should work with docker-compose still.
Jadon
Thank you for making this amazing resource. I am making a bible memory application, and this is used for all the verse content. if you want to check out my (still very much beta) App: https://roadsbible.com
Rob
Nice work!
Henry
Regarding my previous question. I resolved it by making the API call from my backend. Thanks Rob.
Caleb
Hey Rob,
I’ve been working on an app and have been wondering about the licensing side of this. I’ve managed to find an SQLite version of the NIV and the ESV – can I use these in my app?
How are you licensing the versions you’re making available in the API?
Rob
I have not completed any license agreements. Are there any?
Henry
I am getting cors error. i want to test in my dev env then deploy.
Access to XMLHttpRequest at ‘https://bible-go-api.rkeplin.com/v1/books/1/chapters/1/1001002?translation=ESV’ from origin ‘http://localhost:3000’ has been blocked by CORS policy: The ‘Access-Control-Allow-Origin’ header has a value ‘https://bible-ui.rkeplin.com’ that is not equal to the supplied origin.
Steve
Hey Rob! Thanks for all your work! I am looking at the search feature: https://bible-go-api.rkeplin.com/v1/search?query=%5BSearchTerm%5D, and it looks like it only returns 100 results. Is there a way to remove this constraint on the query? Thanks
Rob
Hey, Steve. Yes, there is an offset and limit parameter that you may use to page through the results.
Davidalen Fountain
This is absolutely amazing man. I had this dream of being able to setup a place to do bible study online in the form of SOAP and to share those with friends. To create a place where you can register groups and together do bible study but I was stuck without a good way of implementing scripture. Truly love this!
Rob
Thanks and good luck with your app!
Nathan Worrell
Hey Rob, thank you for providing this awesome resource. You rock! God bless
Chris
for the Rest API is it GET record or Get collection?
I get the following error.
Error: TypeError: Failed to fetch. Does the server allow CORS?status: undefined
Resource settings for Get collection (GET)
——————-
Resource URL: https://bible-go-api.rkeplin.com
Relative path: /v1/translations
Robert
is there no version without the markdown
Rob
None of the versions return text with markdown
Tyler
Thanks for your work friend! May God’s blessings be upon you and your work.
mureithi
Hey can we get a random verse of the day
Rob
Sorry, no – not with the current API.
Eric
I’m having trouble getting this endpoint to work:
GET https://bible-go-api.rkeplin.com/v1/books/%5BBookID%5D/chapters/%5BChapterID%5D/%5BVerseID%5D
This works in the browser:
https://bible-go-api.rkeplin.com/v1/books/1/chapters/1
response:
[{“id”:1001001,”book”:{“id”:1,”name”:”Genesis”,”testament”:”OT”},”chapterId”:1,”verseId”:1,”verse”:”In the beginning God created the heaven and the earth.”},
…
but this doesn’t work:
https://bible-go-api.rkeplin.com/v1/books/1/chapters/1/1
I get this JSON response:
{“code”:404,”status”:”Not Found”,”message”:”Item was not found.”}
Rob
You’ll need to use the Verse ID. Try this:
https://bible-go-api.rkeplin.com/v1/books/1/chapters/1/1001001
Andry
Really love this API! finally found the NIV version,which is pretty rare, I hope you will maintain it!
Rob
Thanks! Glad you found it useful. I hope to maintain it as long as I can.
David Daniel
Hi Kelin,
Thanks for the API endpoints. Been hunting the web searching for a Rest Resource that does not have a limit on the number of requests/day and at the same time support multiple translations. You project helps.
Thanks a ton.