You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Terminal doesn't show hostname anymore

Apple changed something in the Terminal for macOS 15. Instead of showing username and localhost name at the prompt, it now shows username@Mac instead. I have tried various commands using sudo scutil to reset the hostname, but nothing seems to work. Anyone have a solution?

Posted on Sep 17, 2024 5:39 PM

Reply
Question marked as Top-ranking reply

Posted on Sep 18, 2024 4:21 PM

Set your three host names, the traditional full name with domain and dots DNS name, the Bonjour mDNS name (less the .local part), and the so-called friendly name Finder and some other displays use.


sudo scutil --set HostName HostName.example.com 
sudo scutil --set LocalHostName HostName
sudo scutil --set ComputerName FriendlyHostName


Restart Terminal.app. Test again.

16 replies

Terminal doesn't show hostname anymore

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.