Hard boil your eggs. I like to use this method. Place your eggs in a saucepan and cover with water. Bring it to a boil then turn off the heat, cover, and let sit 12 minutes. Rinse with cold water for a couple of minutes, then peel. Or boil eggs with your own method.
Peel eggs and set in a bowl.
Slice your jalapenos, thinly slice some red onion, and peel your garlic cloves, and then hit them gently with the side of your knife to break them open.
In a saucepan over medium heat, heat water, vinegar, salt, and sugar. Bring to a simmer and stir until salt and sugar are dissolved. Turn off heat.
In a quart wide mouth mason jar layer in the eggs, peppercorns, garlic cloves, jalapeno slices, and red onion slices.
Pour hot brine over eggs and seasonings in the jar. Leave about a ¼ inch headspace. Make sure all eggs are under the brine for safety. Seal with a lid. It's best to use a plastic lid for this because of rust, but if you don't have one you can check for rust every week or so and switch lids when needed.
Refrigerate for about 4-7 days before eating for a well-pickled egg. Eat within 4 months.