I have been freelancing as a front-end developer since 4 years but the problem is I get clients only through Upwork and Fiverr. I want clients outside these platforms and only from the USA or European countries. What is the best approach?
To remain a freelancer means that you have to build a business. A business consists of numerous parts including marketing, sales, administration, legal, accounting, etc. When working with platforms such as UpWork, they are acting as your marketing team. To go outside of them, you need to build your own marketing team. If you don't know how to do that, you are better off where you are.
Some people recommend contacting old clients to see if they have work. If you have not kept contact with them, they might not take this contact properly. I do a monthly newsletter to old clients and old prospects that contacted me. I simply offer information, no selling in that newsletter.
Other people talk about using LinkedIn to find people at companies where you want to business and contacting them. Typically, that means paying LinkedIn for the contact information. I get a number of requests "to connect" each month from people who only want to sell me something. In most cases, I turn them down. I would expect a response rate from such prospecting to be similar to any sales call - less than 1 percent will result in a sale.