We have studied the behaviour of the zeotype silicoaluminophosphate SAPO-34 catalyst in the methanolto-olefin (MTO) process under real working conditions using simultaneous synchrotron powder X-ray diffraction (PXRD) and Raman spectroscopy with online analysis of products by mass spectrometry. Anisotropic changes in the unit-cell dimensions are shown to be related to the build-up of intermediate species in the cages of the SAPO-34 framework and also to the deactivation of the catalyst (observed from the products in the mass spectra). We have quantified the amount of intermediate material in the cages from the PXRD using Fourier mapping techniques and our measurements are comparable with tapered element-oscillating microbalance measurements of coke build-up. Raman spectra indicate that the nature of the coke becomes increasingly graphitic with time. Our results also show that the catalyst recovers its original structural parameters when regenerated in air at 500-550 degrees C. (c) 2009 Elsevier Inc. All rights reserved.