• Skip to primary navigation
  • Skip to content
  • Skip to footer
Johnson's Site
  • Posts
  • Cheatsheets
  • Notes
  • Essays
  • Sitemap

    Losing focus on Windows caused by WSL

    WSL steals the active window’s focus.

    Add the following lines to %USERPROFILE%/.wslconfig:

    [wsl2]
    guiApplications=false
    

    and then shutdown WSL:

    wsl --shutdown
    

    Further ReadingPermalink

    1. mstsc.exe stealing focus | Microsoft Community
    2. Disabling WSLg (or using it together with X410)

    Posted: November 14, 2024

    Previous Next

    Comments are configured with provider: disqus, but are disabled in non-production environments.

    • Feed
    © 2025 Johnson. Powered by Jekyll & Minimal Mistakes Template.