How to stop pomodoro clock

Good evening. I hope maybe this time I could have someone help me with my pomodoro project. I’m trying to stop the clock but I can’t seemed to find a way to do it. I’ve tried the clear invterval but it’s not working. If there is someone who has the time to look over my code and can guide me in the right direction I sure would appreciate it. Here’s the link to codepen

I guess the clearInteral is not working because you defined the counter variable inside a function so it cant be used outside the function. If you want to use it globally declare it as a global variable

Uh I see what you mean. I have to set it to a global vaiable and run a separate function. thanks a lot. I’ll try and see if it works.