mpv Audio Device Not Switching: How to Fix It

  • Test mpv audio routing safely without deleting your existing configuration.
  • Identify correct WASAPI, PulseAudio, PipeWire, Bluetooth, and HDMI device names.
  • Find config, profile, script, binding, launcher, and IPC overrides.

When mpv continues playing through the wrong speaker, Bluetooth headset, HDMI display, or audio interface, the problem usually falls into one of four categories: mpv is pinned to a specific output with audio-device, the operating system changed the device identifier after a reconnect, a script or profile is overriding your selection, or the active audio backend is not exposing the device you expect. The safest approach is to isolate device selection from unrelated settings such as subtitles, HDR, shaders, hardware decoding, yt-dlp, and network streaming.

This guide focuses specifically on output device selection. Follow the tests in order, and stop as soon as mpv consistently plays through the intended output. Do not rewrite a large configuration or install codec packs for a symptom that can usually be diagnosed with one clean command.

Desktop audio troubleshooting setup with a terminal, speakers, headset, and monitor.

1. Confirm the Symptom With a Minimal Clean mpv Command

Start with a local media file that you know contains a working audio track. A short MP3, FLAC, or ordinary video file is preferable to an online URL because it removes yt-dlp, authentication, network access, stream format changes, and external tools from the test.

Open a terminal and run mpv without loading your normal configuration:

mpv --no-config "path/to/test-file.mp3"

On Windows, use a quoted path when it contains spaces:

mpv.exe --no-config "C:\Users\YourName\Music\test file.mp3"

While the file is playing, change the default output in the Windows, Linux, or macOS sound controls. Then check whether mpv follows that change. Some audio backends and operating systems can move an active application stream immediately, while others may require the stream to be moved manually or playback to be restarted.

Success means the clean mpv instance plays through the intended device, either after the operating system moves the stream or after you restart mpv. If this works, the media file and basic mpv audio output are functional. The likely cause is now your configuration, a profile, an input binding, or a script. Stop changing operating system drivers and continue with the configuration checks.

If the clean command still uses the wrong output, list the devices mpv can actually address:

mpv --no-config --audio-device=help

Copy the exact device identifier shown by mpv. Do not substitute the friendly label displayed in the operating system settings unless it exactly matches the identifier in mpv's list.

2. Select the Correct Device Explicitly

2.1 Test the audio-device option

The audio-device option tells mpv which output to open. Test it on the command line before saving it in a configuration file:

mpv --no-config --audio-device="DEVICE_IDENTIFIER" "path/to/test-file.mp3"

Replace DEVICE_IDENTIFIER with the complete value reported by --audio-device=help. Quoting is important when a name contains spaces, punctuation, braces, colons, or shell-sensitive characters.

Success means audio immediately comes from the selected speaker, headset, HDMI sink, or interface. Once this test succeeds, stop experimenting with audio drivers. You have a working mpv device identifier and can decide whether the selection should be temporary or persistent.

To return to the backend's default output, test:

mpv --no-config --audio-device=auto "path/to/test-file.mp3"

Using auto is usually preferable when you want mpv to follow the operating system's current default rather than remain pinned to one physical device.

2.2 Understand WASAPI, PulseAudio, and PipeWire names

Device identifiers are backend-specific. A name that works with one audio output driver is not necessarily valid with another.

  • WASAPI on Windows: mpv may expose endpoint-oriented names associated with Windows playback devices. Copy the full identifier from mpv instead of typing the visible speaker label from memory.
  • PulseAudio: outputs are commonly represented as sinks. The stable-looking internal sink name is more useful than a translated desktop label.
  • PipeWire: applications may reach PipeWire through a native integration or a PulseAudio-compatible layer. The identifier visible to mpv depends on the backend mpv is using.
  • macOS: device availability follows the audio devices exposed by Core Audio. Aggregate devices, HDMI outputs, and interfaces can behave differently from the system's ordinary built-in output.

If the intended device is absent from audio-device=help, this is not yet an mpv configuration problem. Confirm that the operating system detects, enables, and permits applications to use the device.

2.3 Use the g-d audio device selector

In mpv builds and default input configurations that provide the g-d audio device selector, press g and then d during playback. Use the selector to choose an output exposed by the active backend. This is a runtime choice, so it is useful for proving that mpv can switch without editing a file.

If g-d does nothing, do not assume audio switching is broken. Your mpv build, custom input.conf, script, or input section may use different bindings. Run a --no-config test, or inspect your input bindings for commands assigned to g or g-d.

Success means the on-screen selection changes and newly played audio reaches the chosen device. If the device works only until mpv exits, the runtime selection is working but has not been made persistent.

2.4 Make the choice persistent only after testing

After an explicit command-line test succeeds, add the following to mpv.conf:

audio-device=DEVICE_IDENTIFIER

Do not include the command-line -- prefix in mpv.conf. Avoid surrounding the value with unnecessary shell-style quoting because the configuration parser is not your terminal shell.

If you regularly move between headphones, HDMI, and speakers, consider leaving audio-device=auto in the configuration and selecting a device at runtime. A permanently pinned endpoint is a common reason for an mpv audio device not switching when the operating system default changes.

3. Check Configurations, Profiles, Bindings, and Scripts

If --no-config works but normal playback does not, something loaded by your regular mpv setup is changing the result. Search your mpv configuration files for these terms:

  • audio-device
  • ao
  • profile
  • set audio-device
  • cycle-values audio-device

Check mpv.conf, input.conf, included configuration files, enabled profiles, and scripts. A profile intended for a television or home theater setup may pin HDMI audio. An input binding may switch devices when a key sequence is pressed. A Lua or JavaScript extension may react to file loading and replace the device selected earlier.

3.1 Inspect active profiles

Use mpv's profile reporting to see the available profile information:

mpv --show-profile=help

To inspect a named profile, use:

mpv --show-profile=PROFILE_NAME

Look for audio-device or ao inside profiles selected manually or automatically. Conditional profiles can activate according to properties such as file type, display characteristics, protocol, or other playback conditions. That can make the problem appear limited to HDR videos, online URLs, playlists, or a specific display even though the actual cause is a profile override.

3.2 Separate track selection from device selection

An audio track and an audio output device are different things. Track selection chooses which soundtrack inside the media is decoded. Device selection chooses where the decoded sound is sent.

If mpv reports audio activity but you hear the wrong language, commentary, or no expected program audio, inspect the track list and cycle or select the correct audio track. If the correct soundtrack plays from the wrong physical speaker, troubleshoot audio-device instead.

Subtitle options do not select audio outputs. Likewise, screenshot settings, subtitle rendering, shaders, HDR tone mapping, and most video filters cannot redirect sound. Disable them only if a conditional profile or script tied to those features also changes audio options.

3.3 Check the output driver before blaming hardware decoding

The ao option selects an audio output driver or backend, while audio-device selects a device available through that backend. A forced ao can therefore change which device names are valid.

Temporarily remove a forced ao setting or compare it with a clean --no-config run. If the device appears only when mpv chooses its output automatically, the forced backend is the relevant difference.

Hardware decoding primarily affects video decoding. It is not the first suspect when sound reaches the wrong physical endpoint. However, HDMI audio can disappear when a GPU driver, dock, display connection, or monitor handshake stops exposing that output to the operating system. In that case, verify that HDMI appears in system sound settings before adjusting hwdec.

Diagram of an application audio stream routed through the operating system to multiple output devices.

4. Check the Operating System and Audio Backend

4.1 Move the active application stream

Changing the system default does not guarantee that every already-running application moves instantly. Open the operating system's per-application mixer or audio routing controls while mpv is producing sound. Confirm that the active mpv stream is assigned to the intended output.

On Linux desktops using PulseAudio or PipeWire compatibility tools, an active stream may be movable independently of the default sink. On Windows, per-application output preferences can keep mpv routed differently from the main default. On macOS, select the intended system output and restart the playback process if the current stream does not migrate.

Success means the active mpv stream is visibly associated with the intended endpoint and sound comes from it. Once that happens, stop modifying mpv unless you want to make the same routing choice permanent.

4.2 Handle Bluetooth reconnect behavior

Bluetooth devices are frequently removed and recreated when they disconnect, reconnect, change profile, or switch between machines. A saved mpv identifier may no longer match the currently exposed endpoint. The operating system may also fall back to speakers while the headset is unavailable.

  1. Reconnect the headset and wait until the operating system shows it as an active playback output.
  2. Run mpv --no-config --audio-device=help again.
  3. Compare the new identifier with the one saved in mpv.conf.
  4. Test the current identifier explicitly.
  5. Use audio-device=auto if stable switching is more important than pinning one Bluetooth endpoint.

Success means a fresh mpv process opens the reconnected headset without falling back to speakers. If the identifier changes after every reconnect, relying on the system default may be more robust than storing a specific name.

4.3 Verify HDMI and audio interfaces

HDMI outputs may exist only while the display, receiver, dock, or capture chain is connected and recognized. USB audio interfaces can also expose multiple playback endpoints. Confirm the exact output and channel mode in system settings, then regenerate mpv's device list.

If the endpoint is absent system-wide, reconnect the cable or interface, verify power and input selection, and check the operating system's audio and display drivers. A GPU driver matters here because HDMI or DisplayPort audio is commonly presented through the graphics device. This is different from changing mpv's video hardware decoder.

5. Use Logs and Runtime Information to Find Overrides

When the cause remains unclear, capture a focused log rather than changing many options. Run:

mpv --log-file=mpv-audio.log --msg-level=ao=trace "path/to/test-file.mp3"

For a clean comparison, add --no-config:

mpv --no-config --log-file=mpv-clean-audio.log --msg-level=ao=trace "path/to/test-file.mp3"

Inspect the logs for the selected audio output driver, attempted device name, initialization failures, fallback behavior, and differences between normal and clean runs. Avoid publishing a full log without reviewing it because command lines, URLs, file paths, usernames, and network details may be present.

The stats overlay is useful for confirming that playback is active and that an audio track is selected, but it is not a substitute for the audio backend log. Similarly, the track list can prove that mpv decoded an audio stream, yet it cannot prove that the operating system routed the stream to the desired physical endpoint.

For IPC-controlled setups, remember that a frontend or automation client can change properties after mpv starts. Compare a direct terminal launch with the command used by your launcher. If direct mpv works but the frontend does not, inspect its arguments and IPC commands for audio-device or ao.

6. Run a Clean Temporary Test Before Making Changes

Use this controlled sequence to isolate the mpv player issue without deleting your configuration:

  1. Choose a known-good local audio file.
  2. Close existing mpv processes so an old instance or IPC controller cannot affect the test.
  3. Connect and enable the desired output in system settings.
  4. Run mpv --no-config --audio-device=help.
  5. Copy the exact current identifier.
  6. Run mpv with --no-config and that explicit device.
  7. If it succeeds, launch normally and compare the result.
  8. Reintroduce your configuration, profiles, scripts, and launcher arguments one category at a time.

This test also works for users who normally play HDR video, subtitle-heavy files, high-bitrate media, network streams, or yt-dlp URLs. Prove local audio routing first. Then retry the original content. If only an online source fails, check whether it actually provides an audio track and whether yt-dlp or network access is functioning. Those issues can produce missing audio, but they do not normally explain sound emerging from the wrong device.

Stop changing settings as soon as the intended endpoint works in both a clean test and your normal launch method. Additional edits make it harder to identify the fix and may introduce new failures.

7. Quick Fix Checklist

  • Run mpv --no-config with a known-good local file.
  • List current outputs with mpv --no-config --audio-device=help.
  • Copy the complete backend-specific device identifier.
  • Test it with --audio-device="DEVICE_IDENTIFIER".
  • Use audio-device=auto when mpv should follow the system default.
  • Try the g-d selector if your build and bindings provide it.
  • Check per-application operating system routing while mpv is playing.
  • Search configs, profiles, bindings, scripts, launchers, and IPC clients for overrides.
  • Reconnect Bluetooth, HDMI, or USB devices before generating the device list.
  • Compare normal and clean logs with --msg-level=ao=trace.
  • Do not alter subtitles, shaders, HDR, or hwdec unless a profile connects them to audio settings.

8. Frequently Asked Questions

8.1 Why does mpv ignore the new default audio device?

mpv may have opened a specific endpoint when playback started, your operating system may preserve the existing application route, or audio-device may pin mpv to another output. Try moving the active stream in system settings, restarting mpv, and testing audio-device=auto.

8.2 Why does the selected device reset when mpv closes?

A selection made through a runtime control is not necessarily written to mpv.conf. After confirming the device works, save audio-device=DEVICE_IDENTIFIER for a fixed output or audio-device=auto for system-default behavior.

8.3 Why is my headset missing from audio-device=help?

The active backend cannot currently see it. Reconnect the headset, select a playback-capable Bluetooth profile, verify it in system sound controls, and rerun the help command. If it remains absent, resolve the operating system or audio-server detection problem first.

8.4 Can subtitles, HDR, or hardware decoding cause the wrong output device?

Not directly in ordinary configurations. They concern text rendering or video processing. They become relevant only when a conditional profile, script, or launcher changes audio options alongside those features. HDMI disappearance can also coincide with a GPU or display problem, but that is endpoint detection rather than video decoding.

8.5 Does yt-dlp determine which speaker mpv uses?

No. yt-dlp can help mpv resolve supported online media and may affect whether an audio stream is available, but output routing remains mpv and operating-system audio behavior. Reproduce the routing problem with a local file before troubleshooting yt-dlp.

8.6 What is the fastest reliable mpv audio device not switching fix?

Run mpv --no-config --audio-device=help, copy the current identifier, and test it explicitly with a local file. If that works, remove or update the conflicting audio-device, ao, profile, binding, script, launcher argument, or IPC command in your normal setup.


Citations

  1. mpv options, audio output drivers, device selection, profiles, logging, and input commands. (mpv Manual)
  2. Official guidance for changing sound output and resolving Windows sound problems. (Microsoft Support)
  3. Official instructions for selecting a sound output device on macOS. (Apple Support)
  4. Technical documentation for PipeWire configuration, tools, and audio behavior. (PipeWire Documentation)
Cindy, ContentBASE creator assistant

MEET CINDY

Your ContentBASE creator assistant

Cindy helps creators find Canva templates, content ideas, and simple ways to make better social media posts faster.

Want ready-to-use templates? Claim the free Canva bundles or browse the full bundle store.