One-pot, three component reaction for the synthesis of pyrrolo[1,2-d][1,4]benzoxazines and pyrrolo[1,2-a]pyrazines is reported. For the synthesis of pyrrolo[1,2-d][1,4]benzoxazines use of 2-aminophenols, dialkylacetylenedicarboxylates and β -nitrostyrene derivatives and Pyrrolo[1,2-a]pyrazines synthesized from reaction of ethylenediamine, dialkylacetylenedicarboxylates and β-nitrostyrene derivatives is discussed.