In this paper, a MEMS-based piezoelectric energy harvester is studied and the whole fabrication process is discussed. The generator structure of composite cantilever with nickel metal mass is devised. MEMS related techniques such as UV-LIGA, ion etching, XeF2 dry etching, wet chemical etching are developed to fabricate the device. This key process includes the bonding a bulk PZT to a Si wafer, and thinning the PZT down to about 15µm in thickness after bonding by mechanical lapping and polishing method. Epoxy resin with a thickness of about 4µm is used as the intermediate adhesive layer. The formed generator is measured on vibration testing setup. The energy under the first resonant mode can be harvested, corresponding to the resonant frequency of 810 Hz . The maximum output voltage under the resonant operation is about 1.23Vp-p.