Scanning tunneling spectroscopy (STS) studies reveal long-range (~100 nm) spatial homogeneity in optimally and underdoped superconducting YBa_2Cu_3O_{7-delta} (YBCO) single crystals and thin films, and macroscopic spatial modulations in overdoped (Y_{0.7}Ca_{0.3})Ba_2Cu_3O_{7-delta} (Ca-YBCO) epitaxial films. In contrast, STS on an optimally doped YBa_2(Cu_{0.9934}Zn_{0.0026}Mg_{0.004})_3O_{6.9} single crystal exhibits strong spatial modulations and suppression of superconductivity over a microscopic scale near the Zn or Mg impurity sites, and the global pairing potential is also reduced relative to that of optimally doped YBCO, suggesting strong pair-breaking effects of the non-magnetic impurities. The spectral characteristics are consistent with d_{x^2-y^2} pairing symmetry for the optimally and underdoped YBCO, and with (d_{x^2-y^2}+s) for the overdoped Ca-YBCO. The doping-dependent pairing symmetry suggests interesting changes in the superconducting ground state, and is consistent with the presence of nodal quasiparticles for all doping levels. The maximum energy gap Delta_d is non-monotonic with the doping level, while the (2Delta_d/k_BT_c) ratio increases with decreasing doping. The similarities and contrasts between the spectra of YBCO and of Bi_2Sr_2CaCu_2O_{8+x} (Bi-2212) are discussed.