Skip to main content
Jellyfin Server provides extensive configuration options to customize your media server experience. Configuration can be managed through the web interface, configuration files, or environment variables.

Configuration Files

Jellyfin stores its configuration in XML and JSON files within the data directory:
/var/lib/jellyfin/
├── config/
   ├── system.xml              # Server configuration
   ├── network.xml             # Network settings
   ├── encoding.xml            # Transcoding settings
   └── logging.json            # Logging configuration
├── data/                       # Database and metadata
├── cache/                      # Temporary cache files
└── log/                        # Server logs

Core Server Settings

Server Configuration (system.xml)

The main server configuration file contains essential settings:
1

Server Name and Culture

Configure the server’s display name and localization settings:
<ServerName>My Jellyfin Server</ServerName>
<UICulture>en-US</UICulture>
<PreferredMetadataLanguage>en</PreferredMetadataLanguage>
<MetadataCountryCode>US</MetadataCountryCode>
2

Metadata Path

Specify where Jellyfin stores metadata:
<MetadataPath>/var/lib/jellyfin/metadata</MetadataPath>
If not specified, metadata is stored in the default internal metadata path within the data directory.
3

Library Settings

Configure library scanning and monitoring:
<LibraryMonitorDelay>60</LibraryMonitorDelay>
<LibraryUpdateDuration>30</LibraryUpdateDuration>
<LibraryScanFanoutConcurrency>0</LibraryScanFanoutConcurrency>
<LibraryMetadataRefreshConcurrency>0</LibraryMetadataRefreshConcurrency>
  • LibraryMonitorDelay: Seconds to wait after file system change (default: 60)
  • LibraryUpdateDuration: Seconds to wait before executing library changed notification (default: 30)
  • Concurrency set to 0 uses automatic values based on CPU count
4

Playback Settings

Configure playback resume behavior:
<MinResumePct>5</MinResumePct>
<MaxResumePct>90</MaxResumePct>
<MinResumeDurationSeconds>300</MinResumeDurationSeconds>
<MinAudiobookResume>5</MinAudiobookResume>
<MaxAudiobookResume>5</MaxAudiobookResume>

Cache Configuration

<CacheSize>10000</CacheSize>
<ImageExtractionTimeoutMs>0</ImageExtractionTimeoutMs>
  • CacheSize: Maximum number of items to cache (default: ProcessorCount * 100)
  • ImageExtractionTimeoutMs: Timeout for image extraction (0 = no limit)

Environment Variables

Jellyfin supports various environment variables for configuration:
Control where Jellyfin stores its data:
JELLYFIN_DATA_DIR=/path/to/data
JELLYFIN_CONFIG_DIR=/path/to/config
JELLYFIN_CACHE_DIR=/path/to/cache
JELLYFIN_LOG_DIR=/path/to/logs

Logging Configuration

Jellyfin uses Serilog for structured logging. Configuration is stored in logging.json:
{
  "Serilog": {
    "MinimumLevel": {
      "Default": "Information",
      "Override": {
        "Microsoft": "Warning",
        "System": "Warning"
      }
    },
    "WriteTo": [
      {
        "Name": "Console",
        "Args": {
          "outputTemplate": "[{Timestamp:HH:mm:ss.fff}] [{Level:u3}] [{ThreadId}] {SourceContext}: {Message:lj}{NewLine}{Exception}"
        }
      },
      {
        "Name": "Async",
        "Args": {
          "configure": [
            {
              "Name": "File",
              "Args": {
                "path": "%JELLYFIN_LOG_DIR%//log_.log",
                "rollingInterval": "Day",
                "retainedFileCountLimit": 3,
                "rollOnFileSizeLimit": true,
                "fileSizeLimitBytes": 100000000,
                "outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss.fff zzz}] [{Level:u3}] [{ThreadId}] {SourceContext}: {Message}{NewLine}{Exception}"
              }
            }
          ]
        }
      }
    ],
    "Enrich": ["FromLogContext", "WithThreadId"]
  }
}

Log Levels

Most detailed logging for debugging:
"Default": "Verbose"

Activity Log Retention

Configure how long activity logs are retained:
<ActivityLogRetentionDays>30</ActivityLogRetentionDays>
Set to null or omit to keep logs indefinitely.

Performance Tuning

Session Management

<InactiveSessionThreshold>0</InactiveSessionThreshold>
Set the threshold in minutes for closing inactive sessions. Set to 0 to disable.

Slow Response Monitoring

<EnableSlowResponseWarning>true</EnableSlowResponseWarning>
<SlowResponseThresholdMs>500</SlowResponseThresholdMs>
Log warnings for requests that take longer than the specified threshold.

Security Settings

Quick Connect

<QuickConnectAvailable>true</QuickConnectAvailable>
Enable or disable Quick Connect for easy device pairing.

Client Log Upload

<AllowClientLogUpload>true</AllowClientLogUpload>
Allow clients to upload logs to the server for troubleshooting.

Legacy Authorization

<EnableLegacyAuthorization>false</EnableLegacyAuthorization>
Only enable legacy authorization if required for compatibility with older clients.

CORS Configuration

Configure Cross-Origin Resource Sharing:
<CorsHosts>
  <string>*</string>
</CorsHosts>
Default allows all origins. For production, specify allowed domains explicitly.

Path Substitution

Map paths for different environments (e.g., Docker, network shares):
<PathSubstitutions>
  <PathSubstitution>
    <From>/media/old-path</From>
    <To>/media/new-path</To>
  </PathSubstitution>
</PathSubstitutions>

Best Practices

1

Backup Configuration

Regularly back up your configuration directory:
tar -czf jellyfin-config-backup.tar.gz /var/lib/jellyfin/config/
2

Use Environment Variables for Containers

When running in Docker, prefer environment variables over editing config files:
environment:
  - JELLYFIN_DATA_DIR=/config
  - JELLYFIN_LOG_DIR=/config/log
3

Monitor Performance

Enable metrics for monitoring:
<EnableMetrics>true</EnableMetrics>
4

Keep Logs Manageable

Configure log retention and size limits to prevent disk space issues.

Next Steps

Network Setup

Configure networking, ports, and remote access

Transcoding

Set up media transcoding and codec options