How to install macros on Logitech mouse
Contents
- What mice are suitable?
- Video guide
- Step-by-step guide
- On-board Memory Mode
- Persistent default profile
- Creating a Lua script
- G HUB script console
- Importing the Lua program (macros)
- Running the Lua program
- Activating weapon modes
- Logitech keyboards and PREMIUM macro versions
- The most common G HUB problems and their solutions
What mice are suitable?
Installing macros, or more precisely Lua programs, into a G HUB script is identical for all Logitech mouse models supported by G HUB (G and PRO series). Other mice, especially those from third-party brands, will definitely not work.
Mice supported by Logitech G HUB
Logitech G102 Prodigy, Logitech G102 LIGHTSYNC, Logitech G103 Prodigy, Logitech G203 Prodigy, Logitech G203 LIGHTSYNC, Logitech G302 Daedalus Prime, Logitech G303 Daedalus Apex, Logitech G303 SHROUD EDITION, Logitech G304 LIGHTSPEED, Logitech G304 SE / G305 SE LIGHTSPEED, Logitech G305 LIGHTSPEED, Logitech G305 X, Logitech G305 X SUPERLIGHT, Logitech G309 LIGHTSPEED, Logitech G402 Hyperion Fury, Logitech G403 Prodigy, Logitech G403 Prodigy Wireless, Logitech G403 HERO, Logitech G502 Proteus Core, Logitech G502 Proteus Spectrum, Logitech G502 HERO, Logitech G502 LIGHTSPEED, Logitech G502 X, Logitech G502 X LIGHTSPEED, Logitech G502 X PLUS, Logitech G600 MMO, Logitech G602, Logitech G603 LIGHTSPEED, Logitech G604 LIGHTSPEED, Logitech G703 LIGHTSPEED, Logitech G703 LIGHTSPEED HERO, Logitech G705, Logitech G900 Chaos Spectrum, Logitech G903 LIGHTSPEED, Logitech G903 LIGHTSPEED HERO, Logitech MX518, Logitech PRO Gaming Mouse, Logitech PRO HERO, Logitech PRO Wireless, Logitech PRO X SUPERLIGHT, Logitech PRO X SUPERLIGHT 2, Logitech PRO X SUPERLIGHT 2 SE, Logitech PRO X SUPERLIGHT 2 DEX, Logitech PRO X SUPERLIGHT 2 DEX SE, Logitech PRO X SUPERLIGHT 2C, Logitech PRO X SUPERLIGHT 2C SE, Logitech PRO 2 LIGHTSPEED, Logitech PRO X2 SUPERSTRIKE, Logitech PRO X3 SUPERSTRIKE.
Special and limited editions (for example, G502 HERO SE or color versions) work the same as the base model.
Video guide
Step-by-step guide
On-board Memory Mode
“On-board Memory Mode” must be disabled, otherwise macros (from Lua programs) will not work in this mode.

Persistent default profile
Go to “Profiles” and make sure your persistent default profile is set to “Desktop”.

“Profiles” in Logitech G HUB

The persistent default profile is “Desktop”
If you set a persistent profile other than Desktop, for example a game profile, there is a chance that macros (the Lua program) will not work.
Creating a Lua script
Now go to the “Desktop” profile and click “Create LUA Script”.

Going to the “Desktop” profile

Creating a script for the Lua program
Click the “CREATE A NEW LUA SCRIPT” button.

G HUB script console
You’ve created a new script, and at the bottom there’s an area (highlighted in red): the script console. If you don’t have it for some reason, or you closed it by accident, be sure to open it.

Clean script and the G HUB console window
To open the console, open the View menu tab and click Console.


Importing the Lua program (macros)
Go to the Script menu and click Import.


In the window that opens, choose the Lua program to load into the script.
![]()
Running the Lua program
Go to the Script menu and click Save and Run.


After launching, if the Lua program is written correctly, there should be no error messages in the G HUB console. If you’re using our programs, a welcome message appears in the console.

Loaded and active Lua program in a G HUB script
Activating weapon modes
Now you can use all the features of the Lua program you loaded. For example, in our Apex Legends pack, to activate the mode for the C.A.R. SMG you hold left ALT and press mouse button 5 (the far side button), as written on line 24 of the script: C.A.R. SMG: LEFT ALT + MOUSE BUTTON 5.
If everything is done correctly, the G HUB console shows a message that the mode for C.A.R. is active.
For the macros of this mode to start working, turn on CapsLock (the G HUB console reminds you if it’s off) and hold RMB (right mouse button, aiming mode in the game) + LMB (left mouse button).
![]()
Don’t forget to set your game settings according to the pack requirements (of the Lua program) to get the maximum recoil reduction.
Logitech keyboards and PREMIUM macro versions
If you have a Logitech keyboard with programmable G keys (for example, the G213 Prodigy) and PREMIUM macros, you can assign each weapon to its own G key (up to 12 weapons with the G213 Prodigy).
The most common G HUB problems and their solutions
It often happens that after connecting a new mouse or updating G HUB, users run into various problems. Thanks to our tech support experience, we’ve collected (and keep collecting) all known Logitech G HUB problems and their solutions in a separate article.

