forked from 0zd3m1r/koreader-xray-plugin
-
Notifications
You must be signed in to change notification settings - Fork 8
1. Get Started
Jimmy Pautz edited this page Jun 30, 2026
·
14 revisions
Here's how to install the plugin and get everything set up.
- Grab the latest release and extract the zip file.
- Copy the
xray.kopluginfolder into your KOReader plugins directory.-
Linux/Android:
~/.config/koreader/plugins/ -
Kindle/Kobo:
mnt/us/koreader/plugins/(or wherever your plugins folder is)
-
Linux/Android:
- Restart KOReader.
The plugin needs an API key to process the book's text. Google Gemini is generally the best option since their free tier gives you plenty of requests.
- Go to Google AI Studio.
- Sign in and click "Create API Key".
- Copy the key.
If you prefer ChatGPT:
- Go to your OpenAI Dashboard.
- Generate a new secret key. (Keep in mind you'll need a funded OpenAI account for this).
- Sign up at the DeepSeek Platform.
- Create an API key in the "API Keys" section.
- Create an account at the Anthropic Console.
- Generate a new key in the "API Keys" section.
- For OpenRouter, grab a key at openrouter.ai.
- For other services, ensure they are OpenAI-compatible and you have their Base URL and Model ID ready.
- Open any book in KOReader.
- Go to Tools Menu → X-Ray → Settings → AI Settings → API Keys & Providers.
- Select your provider and paste your key. For Custom Providers, you'll also need to enter the Base URL and Model ID.
- You can also pick your primary model under AI Settings.
gemini-3.5-flashorgpt-5.4-miniare solid defaults.
Note
You can also paste your API key in the config file: xray_config.lua. For more information on the config file, see Advanced Usage.
The plugin can automatically fetch data in the background as you read. However, you can also trigger a full fetch manually:
- With a book open, navigate to Tools Menu → X-Ray → Fetch X-Ray Data.
- Give it about 30 to 60 seconds to run.
- A summary will pop up when it's done. Everything is now saved locally, so you don't need an internet connection to use X-Ray for this book again.
See the Fetching Data page for a full breakdown of how manual fetching and automatic background fetching work.
Next, check out the Core Content & Features to see what you can do.