Judging by the code, it seems that one must be logged in for it to appear. But I wonder, should it use the Content localization language switcher site setting for the logic instead (@Don)?
It was originally configured that way because guests often navigate pages where the sidebar is completely hidden by the system (such as the full-page login screen), which would have caused the language switcher to disappear entirely for them.
However, I have successfully updated the logic to enable the language selection for guests as well. To ensure a seamless user experience, I implemented a dynamic solution:
Both logged-in users and guests will see the language selector nicely integrated into the sidebar footer.
The system automatically detects that the sidebar is missing and moves the language switcher up to the header, ensuring guests never lose the ability to change the language.
If a user or guest manually closes the sidebar, the switcher remains hidden as intended, keeping the header clean.