Speed and power: These two elements are definitely the most important. Everyone's pain tolerance and massage preferences differ, but anyone can benefit from a massager with at least two settings: one being less intense so you can still use the gun on very sore muscles where you are experiencing muscle tension or pain.
Type of motion: As discussed in the NordicTrack description, percussion and vibration are very different. When shopping for a massage gun, consider which mechanism is more important to you.
Portability: If you're going to be traveling with your massage gun, you'll want one that can easily fit into a bag or suitcase, or one that has its own carrying case. Though most are indeed handheld massagers, some units are rather bulky, such as the TimTam models.
Attachments and accessories: Where on your body will you use the massage gun? If you'll only use it on your large muscles, such as your back and legs, you probably don't need many attachments or accessories. But if you intend to use it on specific areas and trigger points, such as the arch of your foot or your neck, you would benefit from smaller attachments intended for those specific areas.
Battery life: Pretty self-explanatory -- the longer the battery life, the better, as with all electronics.
Cost: You'll want to look for a therapeutic massager device within your budget. The most expensive massage guns usually offer more adjustable speed, power and motion settings, but less expensive models can certainly get the job done.