To demodulate an AM signal, pass it through a rectifier. The amplitude variation will turn into a baseband signal.
There are a few ways to demodulate an FM signal. One is to use two AM demodulators, one tuned to the high end of the band and the other to the low end, and feed the outputs into a difference amp. Another is to feed the signal into a phase-locked loop and use the error signal as the demodulated signal.