Create hidden user accounts in OSX

Step 1) Create user in Accounts with ID < 500 using advanced options
– Remember to change the directory permissions
Step 2) Run the following command.
sudo defaults write /Library/Preferences/com.apple.loginwindow Hide500Users -bool TRUE