How to Change Subtitle Language Track with a Hotkey in mpv?

Switching subtitle tracks in the mpv media player can be done instantly using built-in keyboard shortcuts, eliminating the need to navigate through tedious menus. By default, pressing the j key allows you to cycle forward through all available subtitle languages, while J (Shift + j) cycles backward. This article covers these default hotkeys, explains how to customize them to any key combination you prefer via the input.conf file, and provides tips for setting up automatic language priorities.

Default Hotkeys for Subtitle Management

Out of the box, mpv comes equipped with a few straightforward bindings to manage your subtitles on the fly. You do not need to configure anything to use these:

Using j and J is the quickest way to jump between commentary tracks, different languages, or closed captions during playback.

Customizing Your Subtitle Hotkeys

If the default keys do not fit your workflow, you can easily remap them by editing or creating an input.conf file in your mpv configuration directory.

Step 1: Locate your configuration folder

Depending on your operating system, the configuration folder is typically found here:

Step 2: Edit or create input.conf

Open the input.conf file in a standard text editor (like Notepad or VS Code). If the file doesn’t exist, create a new blank text file and name it input.conf.

Step 3: Add your custom keybindings

Add lines to map your preferred keys to the cycle sub command. For example, if you want to use the S key to cycle subtitles and Ctrl+s to turn them on/off, add the following text:

S cycle sub          # Cycle forward through subtitles
Ctrl+s cycle sub-visibility # Toggle subtitle visibility

Save the file and restart mpv for the changes to take effect.

Automating Your Preferred Languages

If you frequently switch to the same languages, you can instruct mpv to automatically pick your preferred tracks every time you open a video. This reduces the need to use hotkeys at all.

To do this, open your mpv.conf file (located in the same folder as input.conf) and add the slang (subtitle language) property followed by a comma-separated list of language codes:

slang=eng,en,spa,es

In this example, mpv will automatically look for English subtitles first. If they aren’t available, it will fall back to Spanish before trying other languages.