How do I encode special characters (korean/japanese etc)

Hey,

I was working with communicating with a database and setting up a login system. My issue is that the majority of my users are from overseas. I want to know how to encode something like korean or japanese properly because it can’t be sent in a url-encoded form. I tried to encode with base64 but it sends it as “pz8/” in most cases. When i Encode with base64 on websites, it is much longer and can be decoded in my php script. I am just wondering if I am missing something. Any help is appreciated. I have been working on this for the last 3 weeks.