Understanding Mouse Button 4 and Getting It Working Properly
Most mice with side buttons have a forward and backward button. Button 4 is usually the one closer to your thumb when you rest your hand naturally. It registers as a distinct input in Windows, but getting it to do what you actually want is where things get messy. Out of the box, Button 4 sends a generic mouse-side-button-forward signal. Browsers interpret this as "back." Video players sometimes map it to skip forward. A lot of games don't recognize it at all unless you explicitly assign it in their control settings. The problem is that the default behavior is useless for anything beyond basic navigation, and you can't just plug it in and expect it to be productive. I spent about three weeks with a Logitech G502 before I realized the default driver software was the bottleneck. The software would let you assign Button 4 to a macro or a key, but every time I switched profiles, the mapping would silently revert. I ended up just using autohotkey because it stayed consistent across profile changes and didn't require the Logitech suite to be running in the background.
Setting It Up Without Installing Bloatware
The heavy-handed approach is to install whatever manufacturer software comes with your mouse. Razer Synapse, Logitech G Hub, SteelSeries GG. They work if you never switch PCs and your mouse driver doesn't corrupt your profile settings. For most people, that's not the reality. Here's what actually works if you want something lightweight: Download AutoHotkey from the official site. Install it with the default options. Create a new script file on your desktop, right-click it, and select Edit Script. Add something like this:
XButton1::F13 That maps Button 4 to F13, which is an unused key you can then assign in any application. Save the file, double-click it to run, and the mapping is live immediately. You can put a shortcut to that .ahk file in your startup folder if you want it to launch when Windows starts. This approach takes about four minutes total and uses less than 5MB of RAM.
Get the Full Details

Common Pitfalls That Catch People Off Guard
One thing nobody mentions is DPI switching conflict. Some mice let you remap the DPI button through the same software that handles your other buttons. If you accidentally assign Button 4 to cycle DPI while playing a game, it will feel like your mouse is breaking. I hit this exact issue with a Corsair M65 where the Corsair iCUE software had both functions in the same menu and I wasn't paying attention. Took me twenty minutes of trial and error to figure out why my sensitivity was jumping mid-fight. Another issue is game-specific override. Even if Button 4 is mapped to F13 in your system, some games read hardware input directly and ignore your software remapping. Valorant does this. Counter-Strike 2 doesn't. Overwatch 2 does. If a game isn't responding to your Button 4 assignment, check whether it has its own input handler that bypasses Windows-level remapping. There's no universal workaround except switching to a mouse that uses a different polling method or using an external hardware solution like a XIM device, which is overkill for most people.
When Button 4 Isn't Worth the Effort
If you're only using your mouse for office work and web browsing, Button 4 is fine as-is. The default back/forward behavior covers 90% of what you'd need. Mapping it only matters if you're doing something repetitive where a single press saves you from reaching for the keyboard. That's mostly gamers, video editors, and people who use CAD software daily. For video editing, I map Button 4 to play/pause and Button 5 to ripple delete. It cuts my editing time down noticeably once muscle memory kicks in. But that only works after about two weeks of consistent use. Until then, you'll miss presses and get annoyed. Don't expect immediate productivity gains. If your mouse only has two side buttons and they're small and stiff, consider whether the physical design is worth fighting with. I've used mice where Button 4 required a deliberate press to register, and the inconsistency made it worse than not having it at all. Acoustic click quality matters more than marketing pages suggest.