# Timers: setTimeout and setInterval

setTimeout runs a function once after a delay, setInterval runs it again and again, and clearTimeout and clearInterval cancel them with the ID each timer hands back.

![Cheat sheet: Timers: setTimeout and setInterval](https://fsdtrainingmedia.blob.core.windows.net/public/images/2026/10/1e224a70e0754216bb562903fb2aefdf.webp)

- Category: JavaScript
- Level: Apprentice
- Tags: Callback Function, clearInterval(), clearTimeout(), JavaScript, setInterval(), setTimeout()
- Updated: November 1, 2026

Source: https://www.ask-codey.com/cheat-sheets/javascript-async-basics-timers-cheat-sheet
