Óbidos has several gates; this is the one everybody uses, at the south end of the town where the car parks are. It dates in its present form from the reign of King Fernando in the 14th century, and its design is military rather than ceremonial: it is a double gate turned through an angle — em cotovelo, at an elbow — so that anyone forcing the outer arch met a wall, had to turn, and did so with their unshielded side exposed to the wall above. Walk it slowly and you can read the trap in the plan.
Inside the angle, in the wall of the passage, is the oratory of Nossa Senhora da Piedade, the town’s patroness. It has a Baroque balcony and is faced with blue-and-white azulejos of about 1740–50 showing scenes of the Passion, including the Agony in the Garden and the Arrest of Christ. Be clear that this is 18th-century Baroque decoration set into a medieval structure; the 17th-century image of the Virgin that stood in it is now in the Museu Municipal, so the niche you see is empty of its figure.
Above the gate runs the inscription “A Virgem Nossa Senhora foi concebida sem pecado original” — the Virgin was conceived without original sin — which João IV ordered cut there in thanks for the patroness’s protection during the Restoration of Portuguese independence from Spain in 1640.
Practically, this is the pinch point of the whole town. Every coach party enters here and takes the same photograph, so between about 11:00 and 16:00 you will queue to pass through a 14th-century gateway. One of the two stairways onto the wall circuit starts immediately inside it. Standing outside the gate and looking east you can pick out the arcade of the Usseira aqueduct, built on Queen Catherine of Austria’s orders from 1573 to bring water to the town’s fountains — it is worth knowing what it is, but not worth a separate walk.