Sub topic 3
Recording your first action
An action is a saved sequence of Photoshop commands that you can replay on any open image. This chapter walks through creating a set, recording a small action, checking the result, and fixing mistakes. It assumes you can open and save images, use the Layers panel, and run common adjustments, filters and Image Size. It also assumes you know the difference between JPEG, PNG, TIFF and PSD.
What recording actually captures
When you press Record, Photoshop writes down each command you run, along with the values you entered in its dialog. Playback repeats those commands in order, using the stored values. Photoshop does not capture your intent. If you recorded "resize to 1600 pixels wide", it will resize every image to 1600 pixels wide, even one that is only 800 pixels wide.
Keep three rules in mind:
- Actions store settings, not goals. Every dialog value you confirm is stored.
- Actions run against the active document. Whatever is open and selected when you press Play is the target.
- Order matters. Flattening before a filter is not the same as flattening after it.
Open the Actions panel
Choose Window > Actions, or press Alt+F9 (Windows) or Option+F9 (macOS). The panel lists action sets (folders) that hold actions. Each action expands to show its steps. Default actions installed with Photoshop are in a set called "Default Actions".
The buttons along the bottom of the panel are the ones you will use during recording:
| Button | Name | What it does |
|---|---|---|
| Square | Stop playing/recording | Ends a recording or interrupts playback |
| Circle | Begin recording | Starts recording into the selected action |
| Triangle | Play selection | Plays the selected action or step |
| Folder | Create new set | Makes a new folder for actions |
| Page | Create new action | Opens the New Action dialog and starts recording |
| Trash can | Delete | Removes the selected set, action or step |
The Begin recording circle turns red while recording is active. If it is red, everything you do is being captured.
Plan before you record
Recording is easier when you have already decided the steps. Run through the job once by hand on a spare copy of an image, and write down the commands in order. For this chapter, the job is a "web copy":
- Convert the image to the sRGB color profile.
- Resize it to 1600 pixels wide, keeping proportions.
- Apply a light sharpening.
- Save a JPEG copy.
Test images matter. Open a typical photo, such as an RGB JPEG that is larger than 1600 pixels wide. Recording on an unusual file, such as a CMYK or 16-bit image, can store settings that behave oddly on the rest of your files.
Record the action
Step 1: Create a set
Click Create new set (the folder icon). Name it My Actions and click OK. Putting your own actions in your own set keeps them separate from the defaults. That makes them easier to save and share later.
Step 2: Create the action
With the new set selected, click Create new action. In the New Action dialog:
- Name:
Web Copy 1600 - Set:
My Actions - Function Key: optional. A key such as F2 lets you play the action from the keyboard. You can add Shift or Control modifiers.
- Color: optional. The color only matters in Button Mode.
Click Record. Recording starts immediately, and the circle turns red.
Step 3: Perform the steps
Run each command normally, and confirm each dialog with OK.
- Edit > Convert to Profile. Choose sRGB IEC61966-2.1 as the destination space and click OK.
- Image > Image Size. Set the unit to Pixels, set Width to 1600, make sure the chain icon (constrain proportions) is on, and choose a resample method such as Bicubic Sharper (reduction). Click OK.
- Filter > Sharpen > Unsharp Mask. Use Amount 60%, Radius 0.6 pixels, Threshold 2 levels. Click OK.
- File > Save As. Choose JPEG, pick a folder, accept the file name and click Save. Set JPEG Quality to 10 and click OK.
Each command shows up as a new row in the action. If you see a row you did not mean to record, you can remove it later.
Step 4: Stop recording
Click the Stop square. The circle is no longer red. If you forget this step, any command you run afterwards is added to the action.
Play the action
Open a different image from the one you recorded on. Select Web Copy 1600 in the Actions panel and click Play selection. You can also press the function key you assigned.
To run only part of an action, expand it, select a single step and click Play. Photoshop plays from that step to the end of the action. Holding Ctrl (Windows) or Command (macOS) and double-clicking a step plays only that step.
The toggle column on the left of each step shows a check mark. Clicking a check mark turns that step off, so playback skips it. This is useful for testing without deleting anything. A red check mark on the action row means some steps are off.
Check what was recorded
Expand the action by clicking the arrow beside its name. Expand each step to see the stored values. For example, the Image Size step lists the width, unit, resample method and so on. Reading these values is the quickest way to find out why an action behaves differently from what you expected.
Look for these common surprises:
- Save As stores a path. The folder you picked is recorded. Every playback writes to that same folder, with the same file name, unless the Batch command overrides it. A later chapter covers overrides in detail.
- Open and Close steps are recorded too. If you open a file during recording, the action will try to open that same file when it plays.
- Selected layer names can matter. Steps that target a layer by name will fail if a file does not have a layer of that name.
Fix a recording
You rarely get an action right on the first attempt. These are the main ways to repair one.
- Delete a step. Select it and click the trash can, or drag it there.
- Re-record a step. Double-click the step. For steps with a dialog, the dialog opens again so you can enter new values and confirm.
- Add steps in the middle. Select the step you want the new command to follow, click Begin recording, run the command, then click Stop. New steps are inserted after the selected one.
- Add steps at the end. Select the last step, then click Begin recording.
- Change name or key. Double-click the action name, or choose Action Options from the panel menu.
Playback options
Open the panel menu (the icon at the top right) and choose Playback Options. Three modes are available:
| Mode | Behavior | Use it for |
|---|---|---|
| Accelerated | Plays quickly, with minimal screen updates | Normal runs and batches |
| Step by Step | Redraws the image after each step | Finding which step goes wrong |
| Pause For | Waits a number of seconds after each step | Watching an action slowly |
Step by Step is the best debugging tool. Use it when an action produces the wrong result and you cannot tell which command caused it.
Edge cases to know about now
- Tools are not recorded by default. Brush strokes and other tool actions need Allow Tool Recording turned on in the panel menu. Even then, strokes are fixed to the coordinates you used, so they rarely work well across different images. The "What an action cannot record" chapter covers this.
- Undo during recording is unreliable. If you make a mistake, stop recording and delete or re-record the step instead of relying on Undo.
- Dialog values are frozen. If a step needs a different value for each image, the action needs a stop or a modal control. Both are covered in later chapters.
- Different image types can break steps. A filter that works on an 8-bit RGB image may be unavailable on a 16-bit or CMYK one. Playback then stops with an error.
Check your understanding
Exercise
You recorded an action that ends with File > Save As, and you chose the folder "Desktop/exports". You then play it on ten images, and each one is saved as the same file name in that folder. Why does this happen, and how can you see the stored values in the action?
Show answer
Save As is recorded with its folder path and file name, so every playback uses those stored values. The result is that each run overwrites the previous file. Expand the action in the Actions panel, expand the Save step and read the stored settings. The Batch command can override the Save As path and name, which is covered in a later chapter.
Exercise
After stopping a recording, you realize you forgot a sharpening step that should come after the resize and before the save. How do you add it without re-recording the whole action?
Show answer
Select the Image Size step in the action, click Begin recording, run Filter > Sharpen > Unsharp Mask and confirm its dialog, then click Stop. The new step is inserted after the selected step, which places it between the resize and the save.