There are multiple ways that you can upload files into MATLAB Online:
1) You can drag and drop the file into the Current Folder Browser in your MATLAB Online session. This will upload the file into what ever folder you are exploring in the CFB at the time.
2) You can also drag and drop your file into MATLAB Drive online, as indicated by Alex and Gopeshh above
Hope this helps!