Your Armor Class (AC) is how hard you are to hit. Start from the formula that fits your setup — you only ever use one base formula, whichever gives the higher number — and add a shield if you carry one.
No armor: 10 + your Dexterity modifier. Light armor: the armor’s base + your full Dexterity (studded leather = 12 + Dex). Medium armor: base + Dexterity, capped at +2 (half plate = 15 + Dex up to 2). Heavy armor: a flat number with no Dexterity at all (plate = 18).
A shield adds +2. Class features can replace the base entirely: a Barbarian’s Unarmored Defense is 10 + Dex + Constitution, and a Monk’s is 10 + Dex + Wisdom (both only while unarmored). Magic armor, the Defense fighting style, and spells like Shield of Faith stack on top.