Deep frying is the art of making uncooked food crispy, golden brown and delicious.
The process of deep frying is a science. Immersed in hot oil, food heats up and releases bubbles of steam that envelop it. Given enough time, the bubbling subsides as the food dries out and releases less steam. With the moisture gone, the outer layer becomes crispy and brown.
The ideal temperature to achieve this crispy transformation lies between 345 and 375°F (175 and 190°C). The exact temperature depends on the type of food you are frying and the length of time required to cook it.
Generally, you want the outside of the food to be golden brown by the time the inside is fully cooked. For something like a piece of fish, which takes around 3 to 5 minutes to cook, a higher temperature of 375°F will do the trick. A chicken thigh on the other hand requires about 15 minutes to cook and needs a lower temperature of 345°F to avoid burning.

Frying a small strip of battered fish requires a higher temperature to properly brown the coating in time
Now that you have the temperature right, it's best to keep it that way. The secret here is not to fry too much at once.
When you add cold food to hot oil, the temperature of the oil drops. Adding too much at once causes the temperature to drop so low that it can't actually fry anything. Your food may start to absorb the lukewarm oil, resulting in a soggy mess. To avoid this, add food in smaller batches, allowing the temperature to recover between additions.
Cooking longer at lower temperatures allows more moisture to escape from the interior of the food. Once removed from the oil, less steam is released and the coating stays nice and crisp.
To achieve a balance between crispy and juicy, some people like to fry food twice. The first time in oil is used to fry until the food is just cooked. Out of the oil and resting on paper towel, the food will release steam and turn the coating soggy.
Just before serving, the food is fried a second time to remove any surface moisture buildup. This not only crisps up the coating, but helps to achieve a nice golden color.
Lard, saturated fats and fats with high burning temperatures are wonderful for getting things brown and crispy. The Chinese use peanut oil, a mono unsaturated fat, that works very well.
Whenever possible, I also use peanut oil. It is more expensive than standard vegetable oil, but if you save and reuse it a few times, it's worth the expense.
Even though saturated and mono unsaturated fats are great for frying, they are not that good for your health. For those inclined, polyunsaturated fats such as canola, sunflower and other vegetable oils are a healthier choice.
Although they do work, the downside is that polyunsaturated oils don't work as well. Cooked in such oils, your food will never be as crispy, brown or scrumptious.
EditFurther Reading
French Fries