'Have forty winks' is one of those phrases that always comes up in lists of entertaining English idioms, but I've never heard anyone say it. We'd be more likely to say 'have a nap'.
The others are used from time to time. 'Hit the hay' is a variation on 'Hit the sack'. It's not something I'd ever say myself, but the expression exists.