There are two ways of adding pixels to your online store: App pixels and Custom pixels. App pixels are automatically added when an app that uses pixels is installed. App pixels use Shopify APIs to collect customer data from your store, and provide added security due to the isolation of the data collected.
This is not an exhaustive list of possible risks with pixels. Always ensure you understand the code that you add to your online store or store checkout, or hire a Shopify Expert for help with custom pixels.
Pixels are scripts that run in the background of your online store to track customer events. The more scripts you have, the slower your store will run. Additionally, if the script added is broken in some way, then the activity could run indefinitely which will slow down your website or cause content to fail to load.
User privacy is heavily regulated to ensure customer information is protected online. Code snippets can be used to bypass customer consent requirements, which violates the Shopify Terms of Service and can lead to legal liability for you. This is especially true if you live in or serve customers in locations with stricter privacy regulations, such as California or the European Economic Area. Remember that you are responsible for complying with applicable laws and getting all necessary consents when you use pixels to collect customer data. Speak with a lawyer if you are unsure about the requirements that apply to you.