Netflix video streaming database schema

How a video streaming service models its data: films and series in one titles table, seasons and episodes, profiles inside an account, resume positions, per-region licensing windows, My List, ratings and subtitle tracks.

Netflix ER diagram

Netflix video streaming database schema n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 accounts idBIGINT emailVARCHAR password_hashVARCHAR country_codeCHAR currency_codeCHAR max_streamsSMALLINT statusVARCHAR created_atTIMESTAMPTZ subscriptions idBIGINT account_idBIGINT plan_codeVARCHAR statusVARCHAR price_centsINTEGER currency_codeCHAR started_atTIMESTAMPTZ current_period_endTIMESTAMPTZ cancelled_atTIMESTAMPTZ profiles idBIGINT account_idBIGINT nameVARCHAR avatar_keyVARCHAR is_kidsBOOLEAN maturity_ceilingVARCHAR language_codeVARCHAR autoplay_nextBOOLEAN pin_hashVARCHAR created_atTIMESTAMPTZ titles idBIGINT kindVARCHAR nameVARCHAR synopsisTEXT release_yearSMALLINT maturity_ratingVARCHAR runtime_minutesINTEGER original_languageVARCHAR is_originalBOOLEAN added_atTIMESTAMPTZ seasons idBIGINT title_idBIGINT season_numberSMALLINT nameVARCHAR release_yearSMALLINT episodes idBIGINT season_idBIGINT episode_numberSMALLINT nameVARCHAR synopsisTEXT runtime_secondsINTEGER credits_start_sec…INTEGER air_dateDATE media_tracks idBIGINT title_idBIGINT episode_idBIGINT kindVARCHAR language_codeVARCHAR is_forcedBOOLEAN is_sdhBOOLEAN codecVARCHAR availability_windows idBIGINT title_idBIGINT country_codeCHAR starts_atTIMESTAMPTZ ends_atTIMESTAMPTZ is_exclusiveBOOLEAN watch_progress idBIGINT profile_idBIGINT title_idBIGINT episode_idBIGINT position_secondsINTEGER duration_secondsINTEGER completedBOOLEAN watched_atTIMESTAMPTZ list_items profile_idBIGINT title_idBIGINT added_atTIMESTAMPTZ ratings profile_idBIGINT title_idBIGINT ratingVARCHAR rated_atTIMESTAMPTZ devices idBIGINT account_idBIGINT profile_idBIGINT device_typeVARCHAR device_tokenVARCHAR last_ipINET last_seen_atTIMESTAMPTZ

Related database schemas