The mildly basic ionic liquidN,N,N,N-tetramethylguanidinium acetate [TMG][Ac] was found to be a very effective basic catalyst for the one-pot, four-component synthesis of 2H-indazolo[2,1-b]phthalazinetriones by condensation of phthalic anhydride, hydrazinium hydroxide, aromatic aldehydes, and dimedone in high yields at 80 C. [TMG][Ac] catalyzed simple and efficient one-pot four-component reaction of Meldrums acid, ethyl acetoacetate, hydrazine hydrate, and aromatic aldehydes to give dihydro-1H-pyrano[2,3-c]pyrazol-6-ones is reported. The ionic liquid could be recycled several times without loss of efficiency with regards to the reaction times and yields.