1 minute to read

How to Add Confetti to Your React App

Note: This tutorial is for developers. If you're not a developer, check out the rest of our tutorials.


First Create the Confetti Animation

Step 0: Create a custom Confetti animation and generate the code to install on your website by visiting ConfettiPage.com.

Play confetti example

Step 1: Click the black button that says โ€œCopy Codeโ€.

Step 2: On React go to the desired page you want the confetti to be in.

Quick tip: It is recommended to put the confetti animation in the thank you page, to celebrate with your visitor for taking action (signing up, purchase etc).


Then Install the Confetti Code on your Chosen Page

Step 3: Install the confetti code (script tag) into your index.html file.

VERY Important: Make sure to add data-trigger="custom". This will prevent the confetti animation from playing until you programmatically fire it (Step 4).


Step 4. Play the confetti anywhere in your app by calling

window.ConfettiPage.play()


Optional: Remove the Watermark

If you are using the free version, you will see the โ€œConfettiPage.comโ€ branding appear at the bottom left.

If you would like it removed, simply upgrade for a license to use it without the ConfettiPage branding.

Note: Once you pay for a license, you will need to create a new Confetti code as a paying customers which will generate a watermark-free code for you to install.



Ready to make your visitors' hearts dance?