A counter is an electronic or mechanical device used to count and record the number of occurrences of a particular event or process. It is widely used in digital electronics, automation systems, and various industrial applications to track and display counts or cycles.