Add a Login Message to Your Mac Using Terminal or System Preferences

Add a message or greeting to your Mac's login window

Mac users can alter the default Mac login window to include a message or greeting. The message can be for just about any purpose. It can be a simple greeting, such as "Welcome back, buddy" or a silly one, such as "While you were away, I cleaned up all those messy files on your drive. You're welcome."

You have three ways to set the login window message: using OS X Server, with Terminal, or by using the Security & Privacy system preference pane.

Login Message with macOS Server

With macOS Server, you can create a single message and then send it to all of the connected computers. Use the Workgroup Manager tool to set the login message. Once set, the message is propagated to all of the Macs that connect to the server.

Appreciative Road Sign
Mint Images / Getty Images

How to Set the Login Message for Individual Macs Using Terminal

You don't need Server to customize the login message. Two other methods are available. The first uses the Terminal application.

  1. Launch Terminal, located in /Applications/Utilities.

    Terminal in macOS Finder
  2. Type the following command:

    sudo defaults write /Library/Preferences/com.apple.loginwindow LoginwindowText "[Your login window message text goes here]"
    

    Exclamation points are not allowed. Terminal may also reject other special characters. If you enter an invalid character, Terminal will return an error message and abort the action of writing to the file. It won't make any changes on an invalid command.

    Changing the login message in Terminal on a Mac
  3. When you're ready, press Return.

  4. Enter your administrative password if Terminal prompts you to do so.

  5. Close Terminal and go to your Lock Screen by pressing Control+Command+Q to see how your message looks.

    Lock Screen on a Mac with a custom login message

How to Reset the Login Window Message Back to Its Default

To remove the login message text and revert back to the default value of no message being displayed, perform the following steps:

  1. Launch Terminal, if it isn't already open.

  2. At the command prompt, enter:

    sudo defaults write /Library/Preferences/com.apple.loginwindow LoginwindowText ""
    

    This command replaces the login window text with a pair of empty quotation marks.

  3. Press Return.

How to Set the Login Message for Individual Macs Using the Security & Privacy Preference Pane

Using a system preference pane may be the easiest method for setting up a login message. The advantage is that you don’t need to work with Terminal and text commands.

  1. Launch System Preferences by clicking its icon in the Dock, or selecting System Preferences from the Apple menu.

    Mac desktop with the System Preferences command highlighted
  2. Select the Security & Privacy preference pane.

    Security & Privacy Pane
  3. Click the General tab.

    General tab in Security & Privacy
  4. Click the lock icon, located in the bottom left corner of the Security & Privacy window.

  5. Enter an administrator password, and then click the Unlock button.

    Unlock button
  6. Place a checkmark in the box labeled Show a message when the screen is locked.

    Show a message box in Security & Privacy settings
  7. Click the Set Lock Message button.

    Selecting Set Lock Message.
  8. Enter the message you want into the window that appears, and then click OK.

    Set a message for lock screen in macOS

How to Reset the Login Message From the Security & Privacy Preference Pane

If you no longer wish to have a login message be displayed, return to the General tab of your Mac's Security & Privacy preferences and remove the check from the box next to "Show a message when the screen is locked."

Was this page helpful?