My knitting is curling in

I’m knitting a scarf, and while knitting I’ve noticed it’s starting to curl in. I don’t know whether this is because of the yarn (the other scarf I made doesn’t do it, and the yarn is a different texture), or if I’m just doing something wrong. I’m doing a row of knitting, then a row of purlling. Is that it?

In any case, do you know any way of preventing it?

This post can help you:
http://forum.knittinghelp.com/t/faq-is-your-stockinette-curling-heres-the-solution?t=32810

alternating rows of knit and purl is called stockinette stitch and it is the nature of stockinette to curl. The thread recomended above is the place to go to see solutions and ways of handling curly knitting

That is why you will often see patterns for scarves that are garter stitch or moss stitch. These don’t curl in.

Otherwise you will see a stockinette stitch with a garter stitch border where you will knit every stitch on either side or alternating sides, depending on the pattern.

If you don’t, you will just have a tube.

Def. check that link and try your scarf a different way other than stockinette (knit row, then purl row).