Grate the potatoes and onion using a grater, then drain thoroughly.
Mix well with the flour, eggs, and salt and pepper.
Heat the oil in a skillet over medium-high heat.
Scoop up a little of the mixture with a spoon and place it in the pan a few at a time, pressing them down to form patties, and fry for about 5 minutes. Flip them over and fry for another 5 minutes.