How to change the computer name of your Mac

Changing the Computer Name of your Mac is a great way to not only personalize it but, more importantly, to easily locate it within a network when multiple other Macs are present.

While working on a series of posts about Find My iPhone, I realized that my iMac didn’t have a specific Computer Name attached to it. When in Find My iPhone, it would just show up as Unknown. I wasn’t sure how that happened, but I knew I wanted to have a proper name for it just so I could recognize it when looking for it on the local network or when sharing files and documents with it over AirDrop.

The steps to set or change your Mac’s name are quick and easy, but I figured that if you already know how to do it, maybe this post will be a reminder for you to check that your Mac has indeed been given a name that makes sense to you. If not, I’ll show you how to do just that.

Mac Tips banners

Change the name of your Mac

These steps will work to change your Mac device name, no matter what Mac you’re using (iMac, MacBook, MacBook Pro, Mac Pro, Mac mini, Mac Studio, etc.)

On macOS Ventura and later

1) Click the Apple icon () and choose System Settings.

2) Pick General from the left sidebar.

3) Click About.

4) Add the new name in the Name field. Once done, you can exit this screen.

Change Mac name in macOS Ventura

On macOS Monterey and earlier

1) In the menu bar, go to  > System Preferences.

2) Click Sharing.

system preferences sharing

3) In the Computer Name box, type in the name you want to use for your computer.

Change Computer Name of your Mac

4) Close the window, and you’re done.

Rename your Mac with Terminal

For those that are comfortable with the command line, you may use Terminal to set a different name for your Mac.

1) Open the Terminal app on your Mac.

2) Type in the following command, making sure to replace YourNewComputerName with the name you want to set.

sudo scutil --set ComputerName YourNewComputerName

3) Press the Enter key.

4) Type your Mac’s passcode.

5) Reboot your Mac if the new name doesn’t reflect in System Preferences > Sharing.

Note: If you want to set a computer name that has spaces, enclose it in double quotation marks (” “). For example, to rename my Mac to Ankur M1 MacBook Pro, the Terminal command will be sudo scutil --set ComputerName "Ankur M1 MacBook Pro". If I don’t use quotation marks (” “), Terminal will only use the first word (Ankur) and ignore the rest (M1 MacBook Pro).

Terminal command to rename your Mac

As always, feel free to ask if you have any questions.

Check out next: