"Username", "user name" or "user-name"
The OED gives ‘username’ and has three citations, from 1971, 1997 and 2007, in support.
The correct spelling in this case is username.
The username is the (usually unique) thing you type in with your password, for example: bobsmith66.
The user name is the name of the user, the user's real life name, for example: Bob Smith. User name is sometimes used for username, but occasionally it makes a difference, so be clear and avoid the ambiguity. (Better still, use full name when you want them to enter Bob Smith.)
User-name is a variant of username, but this is rarely used if ever.
Obligatory Google Ngram:
In case the link breaks again: username is much more common these days; user-name is not used at all.
I've seen both "username" and "user name" used widely. Both are acceptable. As far as I know, techies mostly prefer "username". "User-name" just seems awkward.