How can I call setInterval on a function with an argument that gets incremented by 1 each time it gets called?

I tried putting the call to setInterval in a for loop, but the loop gets called all together. I also tried doing:

setInterval(function(i++), 3000);

with i starting at 1, but this doesn’t work either.

Any suggestions on how to get around this challenge?