1.) From your Shopify admin, click Online Store, then click “Themes”
2.) Click the … menu at the top, then click Edit HTML/CSS
3.) In the file listing on the left side, click the file name under Layout (e.g., it is theme.liquid in our case)
4.) Scroll to the very bottom, and above the </body> tag, paste your script tag:
5.) Click save in the top right