Here is where you should start from.
𝐒𝐭𝐞𝐩 𝟏 - 𝐈𝐝𝐞𝐧𝐭𝐢𝐟𝐲 𝐭𝐡𝐞 𝐜𝐨𝐮𝐧𝐭𝐫𝐲: Where from you want to do PhD/MS. This is important because the way you secure a scholarship varies from country to country. For example, in Australia, you need to contact the supervisor first. On contrary, in the US, you might need to first secure the scholarship. If you don't have a country preference, well and good. Let's move to step 2.
𝐒𝐭𝐞𝐩 𝟐 - 𝐈𝐝𝐞𝐧𝐭𝐢𝐟𝐲 𝐭𝐡𝐞 𝐬𝐜𝐡𝐨𝐥𝐚𝐫𝐬𝐡𝐢𝐩: Each country offers various types of PhD/MS scholarships. For instance, in Australia, you can either get a university-funded scholarship or your scholarship can come from the professor's funding. Identify it so that you can mention your preference while contacting the professor.
𝐒𝐭𝐞𝐩 𝟑 - 𝐂𝐡𝐞𝐜𝐤 𝐬𝐜𝐡𝐨𝐥𝐚𝐫𝐬𝐡𝐢𝐩 𝐚𝐧𝐝 𝐚𝐝𝐦𝐢𝐬𝐬𝐢𝐨𝐧 𝐫𝐞𝐪𝐮𝐢𝐫𝐞𝐦𝐞𝐧𝐭𝐬: Even if a professor agrees to supervise and fund your PhD/MS, you still need to adhere to the university's requirements.
𝐒𝐭𝐞𝐩 𝟒 - 𝐅𝐮𝐥𝐟𝐢𝐥𝐥 𝐭𝐡𝐞 𝐫𝐞𝐪𝐮𝐢𝐫𝐞𝐦𝐞𝐧𝐭𝐬: Once you identify the requirements, start working on fulfilling the requirements. These requirements can include CV, SOP, research proposal, IELTS, etc. You should fulfill these requirements as soon as possible because these would be requirements in most of the scholarships/admissions you would apply for. Therefore, no point in unnecessary waiting anyway.
𝐒𝐭𝐞𝐩 5 - 𝐅𝐢𝐧𝐝 𝐚 𝐬𝐮𝐩𝐞𝐫𝐯𝐢𝐬𝐨𝐫: Once you identify the scholarship and fulfill the basic requirements, you should find a supervisor most aligned with your research/background. How to find one? Go to the university website and then go to the specific school (e.g., computer science) where you can find the list of all supervisors.
𝐒𝐭𝐞𝐩 6 - 𝐄𝐦𝐚𝐢𝐥 𝐭𝐡𝐞 𝐬𝐮𝐩𝐞𝐫𝐯𝐢𝐬𝐨𝐫: Write a solid and thoroughly proofread email to the identified supervisor. Express your interest in pursuing PhD/MS under his/her supervision. Align your research background with the supervisor's background and demonstrate how you are the best fit for his/her lab. Happy to share an email template if you need one.
𝐒𝐭𝐞𝐩 𝟕: 𝐀𝐩𝐩𝐥𝐲 𝐟𝐨𝐫 𝐚𝐝𝐦𝐢𝐬𝐬𝐢𝐨𝐧 𝐚𝐧𝐝 𝐬𝐜𝐡𝐨𝐥𝐚𝐫𝐬𝐡𝐢𝐩: Once a supervisor agrees then apply for admission and scholarship. If you are applying in a country that doesn't require correspondence with a supervisor, you can go ahead and apply via their online portal without supervisor's approval.
𝐒𝐭𝐞𝐩 𝟖 - 𝐀𝐩𝐩𝐥𝐲 𝐟𝐨𝐫 𝐕𝐢𝐬𝐚: After you successfully secure a PhD/MS position, you will need to apply for a visa. This may require some additional documents.
𝐒𝐭𝐞𝐩 𝟎 - 𝐖𝐡𝐞𝐧 𝐬𝐡𝐨𝐮𝐥𝐝 𝐈 𝐚𝐩𝐩𝐥𝐲? If you have completed your MS/BS and plan to get a PhD position, you should apply now. If you are currently doing MS, you should wait until the last 6 months of your MS.