Notice the pattern
Shrimp sometimes swim after a water change, during mating activity, or when exploring. A short burst from one animal is not enough to diagnose stress.
Repeated frantic swimming across many shrimp, especially with lethargy or deaths, is more concerning. Check temperature, oxygenation, ammonia, and nitrite.
Respond to the likely cause
Confirm the filter is running and the surface has movement. Review whether a new plant, cleaner, fertilizer, or medication was introduced shortly before the behavior changed.
Do not pour in a remedy based only on swimming. Make one evidence-based adjustment at a time and contact the seller or an experienced invertebrate keeper if the problem continues.
For your own tank
Record when the movement starts and whether it follows a water change, feeding, or lights turning on. Check surface movement and equipment first. If the behavior is persistent, test ammonia and nitrite and seek experienced help before adding treatment.
Use these as general hobby references. Test your aquarium and confirm product guidance before making changes.