How to get started with the Script Editor on Mac

If you’re learning to write AppleScript or JavaScript for Automation, then you’ll also want to learn about the Script Editor on Mac.

This built-in tool lets you create, edit, and view scripts for workflows, tools, and apps. Once you create a script, you can easily debug it and compile it. You can also open the scripting dictionary for apps to view the vocabulary and additions.

Here, we’ll walk through the basics for the Script Editor on Mac. From the toolbar and navigation to preferences and options, here’s how to get started.

Script Editor language and toolbar

The Script Editor is in your Utilities folder. You can open it quickly from the Finder menu bar with Go > Utilities or a Spotlight search for “Script Editor”.

Select New Document to create your own script. Start by picking your language from the drop-down on the top left. You can pick AppleScript or JavaScript. Write your script in the main window and select your view for below using the buttons at the bottom. You can see the Description, Result, or the Log which includes Result, Messages, Events, and Replies.

Script Editor Diagram

The toolbar at the top of Script Editor is clean and clear, but you can also use Script in the menu bar. You have buttons from left to right to Record, Stop, Run, and Compile. The two icons on the far right let you show or hide the Accessory View and Bundle Contents.

Script Editor preferences

If you plan to use the Script Editor regularly, there are several settings you can adjust. These let you set the default language, enable code completions, and place the app’s icon in your menu bar.

Open Script Editor > Preferences from the menu bar to make your changes.

General: Set the defaults for using Script Editor as your go-to app and the language you want to use. You can also display the application menu as the a target in the code window, show inherited items in the dictionary viewer, and put the Script icon in your menu bar.

Editing: Enable code completion suggestions, set the tab width in spaces, and turn on line-wrapping and formatting options.

Script Editor Preferences General and Editing

Formatting: Select the font styles, sizes, and colors for categories when using both AppleScript and JavaScript.

History: Enable the log history with unlimited or maximum entries and choose logging only when visible.

Script Editor Preferences Formatting and History

Wrapping it up

Hopefully this how-to for the basics of Script Editor on Mac will get you off to a great start. Are you going to create your own script and if so, will it be a tool, app, or workflow? Let us know!