Configuration Guide
Stirling-PDF can be configured in three ways, depending on your deployment and preferences.
Configuration Methods
1. In-App Settings (Recommended)
If you have login enabled, admins can configure everything through the Settings menu in the application.
To use:
1. Set SECURITY_ENABLELOGIN=true
2. Log in as admin
3. Go to Settings → configure through UI
4. Changes apply immediately, no restart needed
Best for: Production deployments with admin users
2. Environment Variables
Configure via Docker environment variables or system environment variables.
To use:
Best for: Docker deployments, infrastructure-as-code, initial setup
3. Settings File (settings.yml)
Edit /configs/settings.yml directly for advanced configuration.
To use:
Best for: Complex configurations, when you prefer file-based config
Common Settings
Authentication
Enable user login:
SECURITY_ENABLELOGIN=true
SECURITY_INITIALLOGIN_USERNAME=admin
SECURITY_INITIALLOGIN_PASSWORD=changeme123
Default credentials: admin / stirling (change immediately after first login)
Language & Localization
How language selection works:
Stirling-PDF determines the interface language using this priority order:
- User's manual selection (highest priority)
- When a user clicks the language globe icon and selects a language
- Choice is stored in browser's localStorage (persists across sessions)
-
Storage key:
i18nextLng -
Browser's language preference
- Automatically detected from browser's
Accept-Languageheader via thenavigatorAPI -
Example: Firefox set to Swedish (sv-SE) will show Swedish UI
-
System default locale (lowest priority)
- Set via
SYSTEM_DEFAULTLOCALEorsystem.defaultLocale - Only applied if user has no localStorage preference (first-time visitors)
Example:
- Config: SYSTEM_DEFAULTLOCALE=en_GB
- Browser: Swedish (sv-SE)
- Result: UI shows Swedish (browser preference overrides config)
To force a specific default language regardless of browser settings, users must manually select it via the language globe icon.
💡 Tip: Set
SYSTEM_DEFAULTLOCALEto your organization's primary language. Users can always override it using the language selector in the top-right corner.
Deployment Mode
File Upload Limits
SYSTEM_MAXFILESIZE=2000 # MB
SPRING_SERVLET_MULTIPART_MAX_FILE_SIZE=2000MB
SPRING_SERVLET_MULTIPART_MAX_REQUEST_SIZE=2000MB
Memory Management
Specialized Configuration Guides
For advanced features and specific use cases, see these detailed guides:
Authentication & Security
Single Sign-On (SSO) - OAuth2 (Google, GitHub, Keycloak, OIDC) - Enterprise only - SAML2 (Okta, Azure AD) - Enterprise only - Complete configuration examples
System and Security - Split deployment (frontend/backend separation) - CORS configuration - Server certificates - JWT configuration
Fail2Ban Integration - Protect against brute-force attacks - Auto-ban after failed login attempts
Features & Customization
UI Customization - Branding and logos - Theme customization - Custom styling
Endpoint/Feature Control - Enable/disable specific tools - Control feature availability by user/role
Pipeline (Automation) - Automated workflows - Folder scanning - Batch processing - Multi-step operations
Integration & Storage
External Database - PostgreSQL configuration (Pro/Enterprise) - Database migration - Backup strategies
Google Drive File Picker - Direct Google Drive integration - OAuth setup
OCR Configuration - Tesseract language packs - OCR optimization
Usage Monitoring - Prometheus metrics (Pro/Enterprise) - Application monitoring - Performance tracking
Other Configuration
Folder Scanning - Watch folders for automatic processing
Custom Signature Files - Pre-loaded signatures for quick signing
Extra Settings - Logging configuration - Server settings (port, SSL/TLS) - Advanced Spring Boot settings
Configuration Priority
When the same setting is defined in multiple places, this is the order of precedence (highest to lowest):
- Environment Variables
- settings.yml / In-App Settings
- Default values
Environment Variable Format
Convert YAML paths to environment variables:
Becomes:
Rules:
- Uppercase everything
- Replace . with _
- Nested properties become PARENT_CHILD
Troubleshooting
Settings Not Applied
- Check configuration priority (env vars override settings.yml)
- Restart container after changing environment variables
- Check logs:
docker logs stirling-pdf | grep ERROR - Verify file permissions on
/configsvolume
Database Issues
Default database location: /configs/stirling-pdf-DB.mv.db
If missing:
- Ensure /configs volume is mounted
- Check write permissions
- Review startup logs
Next Steps
- Production Deployment: See Production Deployment Guide
- API Usage: See API Documentation
- Tool Reference: See Functionality