Ammonia (NH3) represents a carbon-free hydrogen carrier that can be used as a zero-emission fuel in the maritime and heavy transport sector with hydrogen fuel cells. To use ammonia as feedstock, the hydrogen must be recovered through NH3 decomposition into H2 and N2. Ammonia decomposition by a membrane-enhanced reactor would inherently produce high-purity H2 through the membrane avoiding the need for a costly hydrogen separation/purification unit. Pd-based membrane reactors can obtain full ammonia decomposition and show significantly higher conversion than conventional reactors. However, the H2 permeability is found to be inhibited in the presence of NH3. A further fundamental understanding of the long-term stability and performance of the Pd-based membranes under exposure to NH3 is therefore required. In the current work, the adsorbate-adsorbate interactions during co-adsorption, the influence the presence of NH3 has on the hydrogen dissociation kinetics, and surface segregation effects in the presence of NH3 and/or hydrogen on the surface of Pd and Pd3Ag are investigated in detail using density functional theory calculations. We find that both the hydrogen surface coverage and dissociation kinetics are hindered by the presence of NH3 on the surface, and possible segregation of Ag towards the surface in the presence of NH3, which could explain the reduced hydrogen permeation in NH3.