I tried many of the techniques described here, but always lost track. I purchased a COUNTU Goal counter/timer for about $38 from Amazon and have been very pleased. It's small (you wear it like a ring) and easy to use: just push a button at the end of every lap (or length if you prefer) and it counts them and keeps track of the total elapsed time and the average, fastest, and slowest laps. It's small and light enough that it's not noticeable while swimming. And COUNTU has unique function, vibrate alarm function. If you preset a time goal or lap counting goal, it can vibrate to alarm you when you achieve the goal. There are sensor-based watches that automatically determine when you are swimming and when you are done with each lap or length but they cost a lot more (over $100) and are larger and more obtrusive. However, they isn't suit for everyone, like beginner, elder or crowded swimming lane. So according to my experience, COUNTU is my recommendation. You could see HERE. Or you could check the their Youtube channel.