DocsKeyboardExtract Email Username

Extract the username from an email in RunMacro

Desktop ModeRunMacro 3.5+

The Extract Email Username command reads the email in the clipboard, takes the part before @ (the username), and writes the result back to the clipboard.

Dialog & quick setup

RunMacro Extract Email Username command configuration dialog showing parameter fields
Configuration dialog and parameter fields for the Extract Email Username command in RunMacro.
  1. Put the email in the clipboard (Copy Text from the email field, or Set Clipboard).
  2. Add a Keyboard › Extract Email Username command.
  3. Save. After running, the clipboard holds the username; use Paste from Clipboard to fill it.

Modes & when to use

Desktop Mode

Best for

  • Generate usernames from a list of emails.
  • Process bulk email data in a sign-up workflow.
  • Take the name part to fill a "username" field.

Use an alternative when

  • Do not use it for full email parsing, multiple addresses, display names, or plus-addressing that must be preserved.
Before you run
  • Add Extract Email Username to the macro.
  • Prepare the data or target that Extract Email Username will use.

Example workflow

Example: fill a username from an email

  1. Set Clipboard = john@gmail.com.
  2. Extract Email Username → clipboard becomes john.
  3. Click the username field, Paste from Clipboard.
Expected result: After execution, Extract Email Username completes the described action and makes its result available to the next step.

Tips & limitations

If the clipboard has no @, the command leaves the content as-is and logs a note.
  • It takes the part before @ and overwrites the clipboard; empty or malformed input can produce an empty username.

Applies to RunMacro 3.5+ · Desktop Mode · Windows 10/11

RunMacro robot

Robots do the work. Your time is yours.

Create a robot in minutes, no coding needed. Reliable execution, remote management, transparent costs — and you always stay in control.