Powerline communications (PLC) is a favorable technique for many smart grid applications. By transmitting information over the existing powerline infrastructure, PLC has the benefit of low deployment cost. However, due to low transmit power, limited bandwidth, and harsh channel conditions, reliable long-distance and high-capacity PLC is challenging. Relay-aided (RA-) PLC is promising in addressing these issues. In this paper, we investigate the performance of the amplify-and-forward (AF) RA-PLC system from an information-theoretic perspective. The capacity of AF-based RA-PLC is analyzed for frequency-selective PLC channels. The capacity bounds are derived, and the optimal power allocation between the transmitting nodes and the optimal power distribution over the signal frequency band are obtained. The capacity benefits and features of AF-based RA-PLC are evaluated with two prevalent powerline channel models. Based on the signal attenuation model, the capacity of AF-based RA-PLC is compared with direct-link (DL-)PLC, and the effect of relay location is revealed. In addition, based on the transmission line (TL) model, the effects of branch density and load impedance on the capacity of AF-based RA-PLC are evaluated.