How to record a macro in Chrome and replay it

If you've used macros in Excel or Word, you might expect Chrome to have a Record macro button somewhere. It doesn't, at least not in the normal menus. But Chrome does include a recorder that captures clicks, typing and page navigation and plays them back. It sits inside Chrome DevTools, the developer tools panel, and it's called the Recorder.

This guide shows how to record and replay a flow with it, how to fix the usual replay failures, and where it stops being practical if you just want to repeat the same form work every day.

What the Chrome Recorder does

The Recorder panel saves a series of steps, such as "navigate to this URL", "click this element" and "type this text into this field". You can replay them on the same page later. Google's documentation describes it as a way to record, replay and measure user flows, and it was built mainly for testing and performance work. It still works for simple personal automation.

For each click or input, it stores several selectors, which are different ways of finding the element on the page. During replay it tries them in order and uses the first one that matches.

Step 1: Open the Recorder panel

1. Open the page where your task starts.

2. Open DevTools with F12, Ctrl+Shift+I (Windows/Linux) or Cmd+Option+I (Mac).

3. In DevTools, click the ⋮ (More options) menu, then More tools > Recorder.

- Or press Ctrl+Shift+P / Cmd+Shift+P to open the Command Menu, type Recorder and select Show Recorder.

The panel may be labelled as a preview feature, and menu names can change between Chrome versions.

Step 2: Record your steps

1. Click Create a new recording.

2. Give it a clear name, such as Weekly timesheet submit.

3. Click Start recording.

4. Do the task in the page as you normally would: click fields, type values, choose dropdown options, press submit.

5. Click End recording.

You now have a list of steps. Expand any step to see what it captured: the element's selectors and the value that was typed.

Step 3: Replay it

Click Replay. Chrome runs the steps on the current tab, and the Recorder shows its progress step by step.

If a replay fails or clicks the wrong thing:

Step 4: Export or reuse the recording

You can export a recording, for example as JSON or as a script for Puppeteer (a Node.js library for controlling Chrome). Developers use the exported file to rerun the flow outside DevTools or in automated tests. The exact export formats are listed in Chrome's Recorder features reference.

Practical example

Say you log hours in a web timesheet every Friday, and the project, task code and description are the same each time.

1. Record: open the timesheet, choose the project, type the task code, type the description, click Save.

2. Next Friday: open the page, open DevTools, open the Recorder, pick Weekly timesheet submit and click Replay.

3. Check the result before you leave the page. The Recorder doesn't confirm that the right data was saved. It only reports that each step ran.

Pitfalls to know before you rely on it

Other ways to repeat browser tasks

We're building Ferrywise, a Chrome extension that will let you save repeated form-filling and data-entry steps as reusable rules and run them from the toolbar, including copying a record from one site into another. It isn't available yet. If that's the gap the Recorder leaves for you, you can join the waitlist.

Summary

Try it