Lexora Auto Mode is a modern text-to-speech solution for websites that converts page content into natural AI voice at runtime. It allows developers, publishers, and product teams to add an advanced text-to-speech player to dynamic pages without pre-generating audio files.
This approach is ideal for AI voice readers, accessibility tools, editorial platforms, documentation websites, and applications that need automatic text-to-speech generation directly in the browser.
- HTML integration — add a text-to-speech player using simple markup.
- JavaScript integration — full runtime control for dynamic rendering and applications.
How Auto Text-to-Speech Works
Auto Mode converts website content into speech on demand. When a visitor opens a page, Lexora validates the content, generates AI audio, and starts playback as soon as the first audio segment is ready.
This enables real-time text-to-speech for articles, blogs, documentation, and CMS content without requiring manual audio production.
Text-to-Speech Project Configuration
Before integrating the player, you must configure Auto Mode text-to-speech settings inside the Lexora dashboard.
Open your project and click Setup auto mode.
This configuration defines global behavior for the TTS player, including:
- Default AI voice used for speech synthesis.
- Player interface language.
- Playback features such as sticky player and speed control.
- Visual customization like colors and UI appearance.
- Content validation rules for runtime text-to-speech generation.
Because all settings are project-level, developers can integrate the text-to-speech plugin using minimal code.
Domain and URL Rules for Text-to-Speech Generation
Auto Mode text-to-speech runs only on validated domains. This prevents unauthorized use of your project configuration.
You can also configure URL matching rules to control where the AI voice reader is active.
- Rules can use conditions like
isorcontains. - You can include or exclude specific sections of a website.
- If a page does not match the rules, speech generation is blocked.
Content Length Limit for Speech Generation
To optimize performance, Auto Mode validates only part of the page content. Each project allows configuration of a maximum text length.
- The supported limit is up to 10,000 characters.
- Lower limits can improve text-to-speech generation speed.
- Higher limits allow longer articles to be converted to audio.
Text-to-Speech Credit Usage
Credits are consumed only when new audio is generated. Listening to previously generated speech does not use additional credits.
New text-to-speech generation happens when:
- The validated page content changes.
- The project voice configuration changes.
Because speech is generated for real visitors, high-traffic websites may consume more credits compared to pre-generated audio workflows.
Text-to-Speech Integration
Start by installing the Lexora library on your website. Once the installation is complete, you can integrate Lexora Text to Speech Auto-mode using one of the following approaches:
HTML Integration (Recommended for static pages)
<lexora
data-mode="auto"
data-content-target="#article"
></lexora> Direct text variant
<lexora
data-mode="auto"
data-script="Your text here..."
></lexora> JavaScript Integration (Recommended for dynamic apps and SPAs)
const target = document.querySelector('#lexora-player');
new Lexora(target, {
mode: 'auto',
contentTarget: '#article'
}); Direct script example
new Lexora(target, {
mode: 'auto',
script: 'Your text here...'
});Runtime AI Voice Generation
- Audio is generated progressively to reduce waiting time.
- Playback starts as soon as speech data becomes available.
- Previously generated text-to-speech audio is reused automatically.
- Domain and URL validation rules are enforced server-side.
Text-to-Speech Best Practices
- Use precise content selectors to convert only meaningful text.
- Configure URL rules carefully to avoid unwanted speech generation.
- Choose an appropriate character limit for typical article length.
- Monitor credit usage on high-traffic pages.
- Keep project settings stable to maximize audio caching.