bezier curve loops are twisted
Adjust handle's tilt value

According to a Blender reference manual's page:


  If the “curve path” is 3D, the Tilt value of its control points will be used [...] to twist the “curved” object around it.


See also this page for further explanation, but basically the setting control the direction of the beveled/extruded object along the curve.

You can find the absolute value of the control point tilt in the properties shelf



You can edit the titl value directly there, or tweak it by pressing Ctrl+T shortcut or you can find the operator in the 3D View menu bar-> Curve-> Control points-> Tilt