Some spells require you to maintain Concentration in order to keep their magic active. If you lose Concentration, such a spell ends.
If a spell must be maintained with Concentration, that fact appears in its entry, and the spell specifies how long you can concentrate on it. You can end Concentration at any time (no action required).
Normal activity, such as moving and attacking, doesn’t interfere with Concentration. The following factors can break concentration:
The GM might also decide that certain environmental phenomena, such as a wave crashing over you while you’re on a storm–tossed ship, require you to make a Constitution check to maintain Concentration on a spell.