Knowledge Base updated: 2026-10-20
Kodi knowledge base
Kodi is a cross-platform media center. Its xbmc/ tree contains the application runtime, GUI, media libraries, playback engines, add-on system, PVR, networking, filesystem abstractions, and platform adapters.
Application-wide state is coordinated through component and service managers; persistent media and add-on state is maintained by the relevant library, PVR, and add-on databases. GUI windows, player state, and platform windowing bridge those services to the active user session.
Platform support is built through CMake and platform-specific implementations. The WebAssembly target combines browser windowing, socket shims, XHR-backed files, and WebCodecs playback integration.
flowchart TD
App[Application runtime] --> GUI[GUI shell and guilib]
App --> Playback[Playback system]
App --> Libraries[Media libraries]
App --> Addons[Add-on platform]
App --> PVR[Live TV and recording]
App --> VFS[Virtual filesystem]
App --> Settings[Settings and profiles]
GUI --> Playback
GUI --> Libraries
Libraries --> VFS
Playback --> VFS
Playback --> Engines[Playback engines]
Addons --> PVR
Addons --> Games[Games and RetroPlayer]
Platform[Platform and build integration] --> App
Platform --> WASM[WebAssembly platform]
WASM --> Playback
WASM --> VFS
Glossary
- guilib — Kodi's reusable GUI controls, layout, texture, and window-management framework.
- VideoPlayer — Kodi's primary video playback engine and stream-control implementation.
- RetroPlayer — Kodi's game playback and rendering subsystem for game client add-ons.
- PVR — The subsystem that connects Kodi to live-TV backends, guide data, recordings, and timers.
- special protocol — Kodi URL schemes that resolve virtual locations such as profile, home, and temporary paths.
Codebase-wide invariants
- Platform-specific code must be selected through CMake/platform abstraction points rather than assumed from a single host environment; see
cmake/scripts/**andxbmc/platform/**. - Media access flows through URL-based filesystem interfaces and factories, rather than callers directly depending on a transport implementation; see xbmc/…/File.h and xbmc/…/FileFactory.cpp.
- GUI interaction is message/action driven through guilib controls and the window manager; see
xbmc/guilib/**. - Playback integration uses player abstractions and callbacks so the application is not coupled to a single decoder or renderer; see
xbmc/cores/VideoPlayer/**andxbmc/cores/RetroPlayer/**. - Add-on repositories and installed add-ons are mediated by add-on management rather than direct UI ownership; see xbmc/…/Repository.cpp and
xbmc/addons/**.
Routing table
xbmc/Application.*,xbmc/ServiceManager.*,xbmc/messaging/**-> docs/application-runtime.md- xbmc/Application.cpp, xbmc/Application.h,
xbmc/main/**,xbmc/platform/**/main*-> docs/application-lifecycle.md xbmc/windows/**,xbmc/dialogs/**,xbmc/view/**,addons/skin.*/**-> docs/user-interface-shell.mdxbmc/guilib/**-> docs/gui-framework.mdxbmc/music/**,xbmc/media/**,xbmc/filesystem/MusicDatabaseDirectory/**-> docs/media-libraries.mdxbmc/music/**,xbmc/music/MusicDatabase.*,xbmc/music/tags/**-> docs/music-library.mdxbmc/video/**,xbmc/filesystem/VideoDatabaseDirectory/**-> docs/video-library.mdxbmc/cores/IPlayer.*,xbmc/cores/playercorefactory/**,xbmc/settings/**Player*,xbmc/PlayListPlayer.*-> docs/playback-system.mdxbmc/cores/VideoPlayer/**,xbmc/cores/paplayer/**,xbmc/cores/AudioEngine/**,xbmc/cores/RetroPlayer/**,xbmc/cores/ExternalPlayer/**-> docs/playback-engines.mdxbmc/addons/**,xbmc/interfaces/addon/**-> docs/addon-platform.mdxbmc/addons/AddonManager.*,xbmc/addons/Repository.*,xbmc/addons/AddonDatabase.*,xbmc/addons/AddonInstaller.*-> docs/addon-management.mdxbmc/pvr/**-> docs/live-tv-and-recording.mdxbmc/pvr/PVRManager.*,xbmc/pvr/epg/**,xbmc/pvr/recordings/**,xbmc/pvr/timers/**,xbmc/pvr/addons/**-> docs/pvr-lifecycle.mdxbmc/filesystem/**,xbmc/storage/**,xbmc/media/**-> docs/virtual-filesystem.mdxbmc/network/**,xbmc/networking/**,xbmc/services/**,xbmc/zeroconf/**-> docs/network-services.mdxbmc/settings/**,xbmc/profiles/**,system/settings/**-> docs/settings-and-profiles.mdxbmc/LangInfo.*,xbmc/utils/LangCodeExpander.*,xbmc/utils/Locale.*,addons/resource.language.*/**-> docs/language-and-localization.mdxbmc/interfaces/**,xbmc/utils/JSONVariant*,xbmc/announcement/**-> docs/external-interfaces.mdcmake/**,project/**,tools/buildsteps/**,xbmc/platform/**,xbmc/windowing/**-> docs/platform-build-integration.mdcmake/scripts/wasm/**,cmake/treedata/wasm/**,tools/wasm/**,xbmc/platform/wasm/**,xbmc/windowing/wasm/**-> docs/webassembly-platform.mdxbmc/games/**,xbmc/cores/RetroPlayer/**,xbmc/GUIInfoManager/**Game*-> docs/gameplay-and-retroplayer.md