  Recent observations of the cosmic microwave background (CMB) have extended
the measured power spectrum to higher multipoles $l\gtrsim$1000, and there
appears to be possible evidence for excess power on small angular scales. The
primordial magnetic field (PMF) can strongly affect the CMB power spectrum and
the formation of large scale structure. In this paper, we calculate the CMB
temperature anisotropies generated by including a power-law magnetic field at
the photon last-scattering surface (PLSS). We then deduce an upper limit on the
PMF based on our theoretical analysis of the power excess on small angular
scales. We have taken into account several important effects such as the
modified matter sound speed in the presence of a magnetic field. An upper limit
to the field strength of $|B_\lambda|\lesssim$ 4.7 nG at the present scale of 1
Mpc is deduced. This is obtained by comparing the calculated theoretical result
including the Sunyaev-Zeldovich (SZ) effect with recent observed data on the
small-scale CMB anisotropies from the $Wilkinson Microwave Anisotropy Probe$
(WMAP), the Cosmic Background Imager (CBI), and the Arcminute Cosmology
Bolometer Array Receiver (ACBAR). We discuss several possible mechanisms for
the generation and evolution of the PMF.
