In Japan, Greetings (aisatsu) are very important. In Japan, when you see someone in the morning after you wake up, you must say goodmorning. The same goes for nigt time when you say goodnight. Without using proper greetings it will be viewed as rude.
Unfortunately there is no real, all in one, greeting in Japanese. There are many different greetings depending on the time of day, place and who you are speaking to.
Good morning = ohayou gozaimasu (おはようございます)
Good morning (casual) = ohayou (おはよう)
Good afternoon = konnichi wa (こんにちは)
Good evening = konban wa (こんばんは)
Goodnight = oyasumi nasai (おやすみなさい)
Goodnight (casual) = oyasumi (おやすみ)
Saying goodbye in Japanese is a little more difficult than saying hello to someone. There are different ways to say goodbye depending on who you are talking to, how long you will be gone and where you are located. The most common way to say goodbye to your friends is mata ne (またね) and ja ne (じゃね). However, this is not used with strangers.
Sayounara (さようなら) is a word that is found in all Japanese learning text books. However, this word is rarely used and often misused by non-native Japanese speakers. A better translation for this word would be 'farewell', as it is used when you are saying goodbye to someone for a long time, maybe forever. If you use this word wrong it makes the person feel like you don't want to see them ever again.
Hajimemashite (初めまして) is a standard greeting you say when you meet someone for the first time. It is kind of like saying 'nice to meet you', but it literally means something like 'the first time'.
Yoroshiku onegaishimasu (よろしくお願いします) is a set phrase. It's translation is literally asking for someone to be kind to you. This is used in many different situations. One use is to introduce yourself to someone, in that case it means something like;
● Nice to meet you
● Please take care of me
● I am counting on you
This word is hard to translate into English because no phrase exists. It is almost like saying "I am glad we have met, Please be kind to me, as I will be kind to you in our friendship".
There are different variants of this word depending on the politeness level needed in the situation.
(polite) Douzo yoroshiku (どうぞよろしく)
(casual) Yoroshiku (よろしく)
This word can also be used in situations where you are not meeting someone. You can use this if you have asked someone to do something for you, or someone is helping you do something. In this situation it is like saying;
● Thank you in advance
● I am counting on you