In computing a macro is a predefined sequence of commands, instructions, or keystrokes that are grouped together in a single command used to automate repetitive tasks. By invoking a macro, users can execute a series of operations with a single command, keystroke, or mouse click.